feat: Add unit file.

This commit is contained in:
Nicolas Carlier 2014-11-02 20:06:07 +00:00
parent b81e8ab1b7
commit 8978ddf4f4

View File

@ -0,0 +1,14 @@
[Unit]
Description=Webkookd Server
After=docker.service
Requires=docker.service
[Service]
ExecStartPre=-/usr/bin/docker pull ncarlier/webhookd:latest
ExecStartPre=-/usr/bin/docker kill %p
ExecStartPre=-/usr/bin/docker rm %p
ExecStart=/usr/bin/docker run --rm --name %p -v /var/run/docker.sock:/var/run/docker.sock -v /media/data/webhookd/deploy_rsa:/root/.ssh/id_rsa --env-file /media/data/webhookd/env.conf -P ncarlier/webhookd
ExecStop=/usr/bin/docker stop %p
[X-Fleet]
X-Conflicts=%p@*.service