diff --git a/pkg/cloudlaunch/cloudlaunch.go b/pkg/cloudlaunch/cloudlaunch.go index 0b4169b50..d150457d6 100644 --- a/pkg/cloudlaunch/cloudlaunch.go +++ b/pkg/cloudlaunch/cloudlaunch.go @@ -66,7 +66,7 @@ coreos: [Service] Type=simple - ExecStartPre=/bin/sh -c 'mkdir -p /opt/bin && /usr/bin/curl -f -o /opt/bin/$NAME $URL?$(date +%s) && chmod +x /opt/bin/$NAME' + ExecStartPre=/bin/sh -c 'mkdir -p /opt/bin && /usr/bin/curl --silent -f -o /opt/bin/$NAME $URL?$(date +%s) && chmod +x /opt/bin/$NAME' ExecStart=/opt/bin/$NAME RestartSec=10 Restart=always diff --git a/website/camweb.go b/website/camweb.go index f6413eb5d..0d730ccec 100644 --- a/website/camweb.go +++ b/website/camweb.go @@ -470,9 +470,16 @@ func runDemoBlobserverLoop() { if _, err := exec.LookPath("docker"); err != nil { return } + const name = "demoblob3179" + if err := exec.Command("docker", "kill", name).Run(); err == nil { + // It was actually running. + exec.Command("docker", "rm", name).Run() + log.Printf("Killed, removed old %q container.", name) + } for { cmd := exec.Command("docker", "run", "--rm", + "--name="+name, "-e", "CAMLI_ROOT="+prodSrcDir+"/website/blobserver-example/root", "-e", "CAMLI_PASSWORD="+randHex(20), "-v", camSrcDir()+":"+prodSrcDir,