Compare commits
No commits in common. "95189e503f7e7c02dfbf116ccfe2f6dd747089d4" and "8c3dc221199f300a363ca9bbd577a24fca882ee3" have entirely different histories.
95189e503f
...
8c3dc22119
3 changed files with 2 additions and 18 deletions
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# version=0.6.0
|
||||
# version=0.5.0
|
||||
|
||||
# Function to re-exec the script as another user via sudo (only if needed)
|
||||
exec_as() {
|
||||
|
@ -66,7 +66,6 @@ public_start() {
|
|||
QEMUSH_NAME="$1"
|
||||
|
||||
set -- "$@" \
|
||||
-name "$QEMUSH_NAME" \
|
||||
-monitor "unix:$(pathof socket),server,nowait" \
|
||||
-daemonize
|
||||
if ! "$@"; then
|
||||
|
|
|
@ -1,11 +0,0 @@
|
|||
#!/usr/bin/env sh
|
||||
base=$(echo "$QEMUSH_BASE" | cut -d , -f 1)
|
||||
QEMUSH_BASE=$(echo "$QEMUSH_BASE" | sed "s/^${base}//" | sed 's/^,//')
|
||||
|
||||
set -- "$base" \
|
||||
-fsdev local,security_model=passthrough,id=fsdev0,path="${HOME}/shared/${QEMUSH_NAME}" \
|
||||
-device virtio-9p-pci,id=fs0,fsdev=fsdev0,mount_tag=shared \
|
||||
"$@"
|
||||
|
||||
set -x
|
||||
exec "$@"
|
|
@ -1,10 +1,6 @@
|
|||
#!/usr/bin/env sh
|
||||
set -x
|
||||
|
||||
# What processor architecture to use
|
||||
arch=$QEMUSH_ARCH
|
||||
[ -z "$arch" ] && arch=$(uname -m)
|
||||
|
||||
# How many CPU cores to use
|
||||
nproc=$QEMUSH_NPROC
|
||||
[ -z "$nproc" ] && nproc=$(($(nproc) / 2))
|
||||
|
@ -14,7 +10,7 @@ ram=$QEMUSH_RAM
|
|||
[ -z "$ram" ] && ram=$(($(free | grep '^Mem:\s' | awk '{ print $NF }') / 2))K
|
||||
|
||||
# Set the arguments
|
||||
set -- "qemu-system-${arch}" \
|
||||
set -- qemu-system-x86_64 \
|
||||
-enable-kvm \
|
||||
-M q35 \
|
||||
-cpu host -smp "$nproc" \
|
||||
|
|
Loading…
Reference in a new issue