introduce image-updater
This commit is contained in:
@@ -4,12 +4,6 @@ depend() {
|
||||
need docker tsdns
|
||||
}
|
||||
|
||||
start_pre() {
|
||||
until docker pull git.sfclub.cc/cloud/workspace-image:latest; do
|
||||
sleep 10
|
||||
done
|
||||
}
|
||||
|
||||
command="/usr/bin/bubble"
|
||||
command_args="-config /daemon/config.yaml 2>&1"
|
||||
pidfile="/run/${RC_SVCNAME}.pid"
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
#!/sbin/openrc-run
|
||||
|
||||
depend() {
|
||||
need docker
|
||||
}
|
||||
|
||||
supervisor="supervise-daemon"
|
||||
restart_max=5
|
||||
restart_delay=10
|
||||
|
||||
command="/usr/bin/image-updater"
|
||||
pidfile="/run/${RC_SVCNAME}.pid"
|
||||
@@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
while true; do
|
||||
docker pull git.sfclub.cc/cloud/workspace-image:latest
|
||||
sleep 3600
|
||||
done
|
||||
Reference in New Issue
Block a user