mirror of
https://github.com/YunoHost/yunorunner.git
synced 2024-09-03 20:05:52 +02:00
Cleanup incus too
This commit is contained in:
parent
46b86e3070
commit
f5d720ca3a
2 changed files with 8 additions and 7 deletions
|
@ -36,17 +36,17 @@ echo_bold () {
|
||||||
|
|
||||||
# -----------------------------------------------------------------
|
# -----------------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
function tweak_yunohost() {
|
function tweak_yunohost() {
|
||||||
|
|
||||||
#echo_bold "> Setting up Yunohost..."
|
#echo_bold "> Setting up Yunohost..."
|
||||||
#local DIST="bullseye"
|
#local DIST="bullseye"
|
||||||
#local INSTALL_SCRIPT="https://install.yunohost.org/$DIST"
|
#local INSTALL_SCRIPT="https://install.yunohost.org/$DIST"
|
||||||
#curl $INSTALL_SCRIPT | bash -s -- -a
|
#curl $INSTALL_SCRIPT | bash -s -- -a
|
||||||
|
|
||||||
#echo_bold "> Running yunohost postinstall"
|
#echo_bold "> Running yunohost postinstall"
|
||||||
#yunohost tools postinstall --domain $domain --password $yuno_pwd
|
#yunohost tools postinstall --domain $domain --password $yuno_pwd
|
||||||
|
|
||||||
# What is it used for :| ...
|
# What is it used for :| ...
|
||||||
#echo_bold "> Create Yunohost CI user"
|
#echo_bold "> Create Yunohost CI user"
|
||||||
#local ynh_ci_user=ynhci
|
#local ynh_ci_user=ynhci
|
||||||
|
@ -65,8 +65,8 @@ function tweak_yunohost() {
|
||||||
|
|
||||||
function tweak_yunorunner() {
|
function tweak_yunorunner() {
|
||||||
echo_bold "> Tweaking YunoRunner..."
|
echo_bold "> Tweaking YunoRunner..."
|
||||||
|
|
||||||
|
|
||||||
#if ! yunohost app list --output-as json --quiet | jq -e '.apps[] | select(.id == "yunorunner")' >/dev/null
|
#if ! yunohost app list --output-as json --quiet | jq -e '.apps[] | select(.id == "yunorunner")' >/dev/null
|
||||||
#then
|
#then
|
||||||
# yunohost app install --force https://github.com/YunoHost-Apps/yunorunner_ynh -a "domain=$domain&path=/$ci_path"
|
# yunohost app install --force https://github.com/YunoHost-Apps/yunorunner_ynh -a "domain=$domain&path=/$ci_path"
|
||||||
|
@ -202,7 +202,7 @@ EOF
|
||||||
|
|
||||||
function add_cron_jobs() {
|
function add_cron_jobs() {
|
||||||
echo_bold "> Configuring the CI..."
|
echo_bold "> Configuring the CI..."
|
||||||
|
|
||||||
# Cron tasks
|
# Cron tasks
|
||||||
cat >> "/etc/cron.d/yunorunner" << EOF
|
cat >> "/etc/cron.d/yunorunner" << EOF
|
||||||
# self-upgrade every night
|
# self-upgrade every night
|
||||||
|
|
1
run.py
1
run.py
|
@ -570,6 +570,7 @@ async def cleanup_old_package_check_if_lock_exists(worker, job, ignore_error=Fal
|
||||||
|
|
||||||
# Dirty hack to kill ~zombi processes adopted by init doing funky stuff -_-
|
# Dirty hack to kill ~zombi processes adopted by init doing funky stuff -_-
|
||||||
os.system("for PID in $(ps -ef --forest | grep 'lxc exec' | grep ' 1 ' | awk '{print $2}'); do kill -9 $PID; done")
|
os.system("for PID in $(ps -ef --forest | grep 'lxc exec' | grep ' 1 ' | awk '{print $2}'); do kill -9 $PID; done")
|
||||||
|
os.system("for PID in $(ps -ef --forest | grep 'incus exec' | grep ' 1 ' | awk '{print $2}'); do kill -9 $PID; done")
|
||||||
os.system("for PID in $(ps -ef --forest | grep 'script -qefc' | grep ' 1 ' | awk '{print $2}' ); do kill $PID; done")
|
os.system("for PID in $(ps -ef --forest | grep 'script -qefc' | grep ' 1 ' | awk '{print $2}' ); do kill $PID; done")
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue