Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
simple-vm-manager
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Recolic
simple-vm-manager
Commits
dbb36f08
There was an error fetching the commit references. Please try again later.
Commit
dbb36f08
authored
11 months ago
by
Recolic
Browse files
Options
Downloads
Patches
Plain Diff
.add new default base img, add flock
parent
e6f90ea2
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+10
-1
10 additions, 1 deletion
README.md
cron-callback.sh
+3
-0
3 additions, 0 deletions
cron-callback.sh
with
13 additions
and
1 deletion
README.md
+
10
−
1
View file @
dbb36f08
...
...
@@ -24,7 +24,7 @@ Any of: aria2c / wget / curl
1.
Download this repo to anywhere.
2.
Modify
`init.settings`
and
`runtime.settings`
.
3.
Add
`*
/2
* * * * cd /path/to/my/repo && ./cron-callback.sh`
into your crontab.
3.
Add
`* * * * * cd /path/to/my/repo &&
flock -n /tmp/.vmm.lockfile
./cron-callback.sh`
into your crontab.
## Supported cloudimg
...
...
@@ -33,6 +33,15 @@ Any of: aria2c / wget / curl
|Ubuntu 2204 LTS |
`focal-server-cloudimg-amd64.img`
|
|Arch Linux Rolling|
`Arch-Linux-x86_64-cloudimg.qcow2`
|
## Supported back image
**Warning**
: This is unofficial back image built by myself. It has preset username and password.
**USE IT AT YOUR OWN RISK!!!**
.
|||
| --- | --- |
|Windows 10 Pro 22H2|
`win10pro-22h2-virtio-uefi.qcow2`
|
|Tiny10 Minimal 21H2|
`win10-tiny10-virtio-uefi.qcow2`
|
## FAQ
### SSH not working for my new VM
...
...
This diff is collapsed.
Click to expand it.
cron-callback.sh
+
3
−
0
View file @
dbb36f08
...
...
@@ -39,6 +39,8 @@ 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[
"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
[
!
"
${
knowledge
[
$cloudimg
]+abc
}
"
]
&&
echo2
"Unknown cloudimg
$cloudimg
. cannot download it."
&&
return
1
echo2
"+ Downloading cloudimg
$cloudimg
..."
...
...
@@ -75,6 +77,7 @@ function create_vm_if_not_exist () {
qemu-img resize
"vm/
$name
/disk.img"
"
$disk
"
||
return
$?
else
# create from baseimg
download_cloud_img_if_not_exist
"
$cloudimg
"
||
return
$?
qemu-img create
-f
qcow2
-F
qcow2
-b
"../../base/
$cloudimg
"
"vm/
$name
/disk.img"
||
return
$?
fi
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment