Skip to content
Snippets Groups Projects
Commit 19abdd88 authored by Recolic's avatar Recolic :house_with_garden:
Browse files

u

parent aed999fd
No related branches found
No related tags found
No related merge requests found
#!/bin/bash
# You may change this directory
workdir=/extradisk/simple-vm-manager/data
svm_workdir="${svm_workdir:-./data}"
ver=1.0.62
_self_bin_name="$0"
......@@ -54,6 +54,10 @@ function download_cloud_img_if_not_exist () {
declare -A knowledge
knowledge["focal-server-cloudimg-amd64.img"]=https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img
knowledge["ubuntu-18.04-server-cloudimg-amd64.img"]=https://cloud-images.ubuntu.com/releases/18.04/release/ubuntu-18.04-server-cloudimg-amd64.img
knowledge["ubuntu-22.04-server-cloudimg-amd64.img"]=https://cloud-images.ubuntu.com/releases/22.04/release/ubuntu-22.04-server-cloudimg-amd64.img
knowledge["ubuntu-24.04-server-cloudimg-amd64.img"]=https://cloud-images.ubuntu.com/releases/24.04/release/ubuntu-24.04-server-cloudimg-amd64.img
knowledge["ubuntu-24.04-server-cloudimg-arm64.img"]=https://cloud-images.ubuntu.com/releases/24.04/release/ubuntu-24.04-server-cloudimg-arm64.img
knowledge["Arch-Linux-x86_64-cloudimg.qcow2"]=https://geo.mirror.pkgbuild.com/images/latest/Arch-Linux-x86_64-cloudimg.qcow2
knowledge["win10pro-22h2-virtio-uefi.qcow2"]=https://recolic.net/hms.php?/systems/win10pro-22h2-virtio-uefi.qcow2
knowledge["win10-tiny10-virtio-uefi.qcow2"]=https://recolic.net/hms.php?/systems/win10-tiny10-virtio-uefi.qcow2
......@@ -173,8 +177,8 @@ for pid in $(pidof -x "$0"); do
fi
done
mkdir -p "$workdir"
cd "$workdir" || exit $?
mkdir -p "$svm_workdir"
cd "$svm_workdir" || exit $?
mkdir -p base vm tmp
do_init
......
......@@ -15,6 +15,6 @@ lc_startup () {
lc_bgrun /tmp/frpc.log auto_restart bash -c "curl -s https://recolic.net/api/ms-rpctl.php | grep rp.enabled=1 && frpc -c files/secrets/mspc-frpc.ini ; sleep 10m"
lc_bgrun /tmp/cron.log every 30m bash utils/mspc-check-internet.sh
lc_bgrun /tmp/cron.log every 1m bash files/mspc-simple-vmm/cron-callback.sh
lc_bgrun /tmp/cron.log every 1m env svm_workdir=/extradisk/simple-vm-manager/data bash files/mspc-simple-vmm/cron-callback.sh
lc_bgrun /tmp/cron.log every 5m curl https://recolic.net/api/mspc-keepalive.php
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment