2017-12-29 16:31:48 +01:00
|
|
|
#!/sbin/openrc-run
|
|
|
|
|
|
|
|
description="GNU Health docker container"
|
|
|
|
|
|
|
|
depend() {
|
2018-04-25 11:21:26 +02:00
|
|
|
need docker postfix postgres
|
2017-12-29 16:31:48 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
start() {
|
2018-01-27 14:08:19 +01:00
|
|
|
/usr/bin/docker run -d --rm \
|
|
|
|
--name gnuhealth \
|
|
|
|
-h gnuhealth \
|
2018-02-03 11:20:40 +01:00
|
|
|
--link postfix \
|
2018-01-27 14:08:19 +01:00
|
|
|
--link postgres \
|
|
|
|
-v /srv/gnuhealth/conf:/srv/gnuhealth/gnuhealth/tryton/server/config \
|
|
|
|
gnuhealth
|
2017-12-29 16:31:48 +01:00
|
|
|
}
|
|
|
|
|
2018-03-25 23:10:39 +02:00
|
|
|
start_post() {
|
2018-09-04 21:42:26 +02:00
|
|
|
/usr/bin/vmmgr register-proxy gnuhealth
|
2018-04-29 20:48:57 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
stop_pre() {
|
2018-09-04 21:42:26 +02:00
|
|
|
/usr/bin/vmmgr unregister-proxy gnuhealth
|
2018-03-25 23:10:39 +02:00
|
|
|
}
|
|
|
|
|
2017-12-29 16:31:48 +01:00
|
|
|
stop() {
|
2018-04-29 22:17:37 +02:00
|
|
|
/usr/bin/docker kill -s SIGINT gnuhealth
|
2017-12-29 16:31:48 +01:00
|
|
|
}
|