From: Lucas Werkmeister Date: Tue, 8 Jan 2019 21:42:27 +0000 (+0100) Subject: Merge changes I3d69d1c6,I8b0fa62a,I668a5e8d,Iaf0e30fa X-Git-Url: https://code.wpia.club/?a=commitdiff_plain;h=ec411b00d9969e8a56d313cbb7479bba600244d9;hp=76ba67a2528279e3e542bdf36db749667eb80c6f;p=infra.git Merge changes I3d69d1c6,I8b0fa62a,I668a5e8d,Iaf0e30fa * changes: add: motion system from source add: virtual resource collectors for nginx+pg chg: use explicit resources for nginx-binds chg: extract lxc-bind-mounts to own resources --- diff --git a/manager/setup b/manager/setup index 0c5643b..7f38205 100755 --- a/manager/setup +++ b/manager/setup @@ -36,7 +36,7 @@ function reset_vm { } function update { title 'S1: apt-get; clone' - ssh_target -t "( sudo apt-get update | cat ) && ( DEBIAN_FRONTEND=noninteractive sudo -E apt-get upgrade -o Dpkg::Options::=\"--force-confold\" -y | cat ) && ( sudo apt-get install -y git curl $devPkgs | cat )" + ssh_target -t "{ sudo apt-get update && DEBIAN_FRONTEND=noninteractive sudo -E apt-get upgrade -o Dpkg::Options::=\"--force-confold\" -y && sudo apt-get install -y git curl $devPkgs; } | cat" echo "Git init" ssh_target -t '[[ -d .git ]] || git init;' echo "Git push" diff --git a/modules/lxc/manifests/init.pp b/modules/lxc/manifests/init.pp index 3693966..bf71013 100644 --- a/modules/lxc/manifests/init.pp +++ b/modules/lxc/manifests/init.pp @@ -89,6 +89,7 @@ class lxc { } -> exec {"lxc-$contname-started": path => '/usr/bin', refreshonly => true, + # TODO use `systemctl is-system-running --wait` in systemd v240+ refresh => "/usr/bin/lxc-stop -n $contname ; /usr/bin/lxc-start -dn $contname; /usr/bin/lxc-attach -n $contname -- bash -c 'while ! [[ -S /run/systemd/private ]]; do sleep 1; done'", }-> exec {"lxc-$contname-started1": command => "/usr/bin/lxc-start -dn $contname; /usr/bin/lxc-attach -n $contname -- bash -c 'while ! [[ -S /run/systemd/private ]]; do sleep 1; done'",