[Unit]
Description=Drone.io continunous integration and delivery database
After=docker.service
Requires=docker.service

[Service]
TimeoutStartSec=0
ExecStartPre=-/usr/bin/docker kill dronedb
ExecStartPre=/usr/bin/docker pull postgres
ExecStart=/usr/bin/docker run --name drone-db postgres
ExecStop=/usr/bin/docker kill drone

[Install]
WantedBy=multi-user.target
