Spotter-VM/extra/graveyard/crisiscleanup3/etc/init.d/crisiscleanup

30 lines
498 B
Plaintext
Raw Normal View History

#!/sbin/openrc-run
description="Crisis Cleanup docker container"
depend() {
need docker postfix postgres
}
start() {
/usr/bin/docker run -d --rm \
--name crisiscleanup \
-h crisiscleanup \
--link postfix \
--link postgres \
-v /srv/crisiscleanup/conf:/srv/crisiscleanup/config \
crisiscleanup
}
start_post() {
/usr/bin/spotter-appmgr register-proxy crisiscleanup
}
stop_pre() {
/usr/bin/spotter-appmgr unregister-proxy crisiscleanup
}
stop() {
/usr/bin/docker stop crisiscleanup
}