From: xf0r3m Date: Tue, 18 Jul 2023 17:04:05 +0000 (+0200) Subject: Aktywacja poleceń tworzących kontenery, tworzenie kontenerów, funkcja 'idle-fetch... X-Git-Url: https://gitweb.morketsmerke.org/?a=commitdiff_plain;h=5743fe054deb494dee97af97a6b7e7ce24709a03;p=idle.git Aktywacja poleceń tworzących kontenery, tworzenie kontenerów, funkcja 'idle-fetch-containers', skrypt 'idle.sh' --- diff --git a/idle.sh b/idle.sh index a163278..a9402df 100644 --- a/idle.sh +++ b/idle.sh @@ -67,9 +67,12 @@ function idle-fetch-containers() { if grep -q $containerName $DATABASE; then containerImagePath=$(grep $containerName $DATABASE | cut -d ";" -f 1); startupScript=$(grep $containerName $DATABASE | cut -d ";" -f 4); - echo "lxc launch $containerImagePath $containerName"; - echo "lxc file push ${HOME}/idle/$startupScript ${containerName}/root/${startupScript}"; - echo "lxc exec $containerName /bin/bash /root/${startupScript}"; + #echo "lxc launch $containerImagePath $containerName"; + /usr/bin/lxc launch $containerImagePath $containerName; + #echo "lxc file push ${HOME}/idle/$startupScript ${containerName}/root/${startupScript}"; + /usr/bin/lxc file push ${HOME}/idle/$startupScript ${containerName}/root/${startupScript} + #echo "lxc exec $containerName /bin/bash /root/${startupScript}"; + /usr/bin/lxc exec $containerName /bin/bash /root/${startupScript} echo "Container is ready for work."; else echo "Given container name doesn't exist in project database";