Spotter-VM/postgres/etc/init.d/postgres

17 lines
275 B
Plaintext
Executable File

#!/sbin/openrc-run
description="Postgres docker container"
depend() {
need docker net
use dns logger netmount
}
start() {
/usr/bin/docker run -d --rm --name postgres -h postgres -v /srv/postgres:/var/lib/postgresql postgres
}
stop() {
/usr/bin/docker stop postgres
}