Skip to content

Instantly share code, notes, and snippets.

@abn
Created June 11, 2015 05:18
Show Gist options
  • Select an option

  • Save abn/b047e07ddc71ff6362c0 to your computer and use it in GitHub Desktop.

Select an option

Save abn/b047e07ddc71ff6362c0 to your computer and use it in GitHub Desktop.
Enable cockpit on Fedora 22
#!/usr/bin/env bash
# based on instructions provided at
# http://www.projectatomic.io/blog/2015/06/running-cockpit-as-a-service/
atomic info fedora/cockpitws
atomic install fedora/cockpitws
cat > /etc/systemd/system/cockpitws.service << EOF
[Unit]
Description=Cockpit Web Interface
Requires=docker.service
After=docker.service
[Service]
Restart=on-failure
RestartSec=10
ExecStart=/usr/bin/docker run --rm --privileged --pid host -v /:/host --name %p fedora/cockpitws /container/atomic-run --local-ssh
ExecStop=-/usr/bin/docker stop -t 2 %p
[Install]
WantedBy=multi-user.target
EOF
systemctl daemon-reload
systemctl enable cockpitws.service
systemctl start cockpitws.service
systemctl status cockpitws.service
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment