From 90ee7c1b3f34050ff313e58b43451fe32774f7be Mon Sep 17 00:00:00 2001 From: Neilpang Date: Sat, 11 Nov 2023 02:32:05 +0000 Subject: [PATCH] Generated from https://github.com/vmactions/base-vm --- .github/tpl/README.tpl.md | 4 ++-- .github/workflows/test.yml | 4 ++-- run.sh | 10 ++++++++-- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/.github/tpl/README.tpl.md b/.github/tpl/README.tpl.md index 9702cd1..3b084d7 100644 --- a/.github/tpl/README.tpl.md +++ b/.github/tpl/README.tpl.md @@ -140,7 +140,7 @@ You can add NAT port between the host and the VM. ``` -The default memory of the VM is 1024MB, you can use `mem` option to set the memory size: +The default memory of the VM is 6144MB, you can use `mem` option to set the memory size: ``` ... @@ -152,7 +152,7 @@ The default memory of the VM is 1024MB, you can use `mem` option to set the memo with: envs: 'MYTOKEN MYTOKEN2' usesh: true - mem: 2048 + mem: 4096 ... ``` diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e97cf88..745ba82 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -31,7 +31,7 @@ jobs: release: [ "13.2", ""] runs: [ "ubuntu-22.04"] runs-on: ${{ matrix.runs }} - name: A job to run test sshfs FreeBSD + name: sshfs FreeBSD env: MYTOKEN : ${{ secrets.MYTOKEN }} MYTOKEN2: "value2" @@ -64,7 +64,7 @@ jobs: release: [ "13.2", ""] runs: [ "ubuntu-22.04"] runs-on: ${{ matrix.runs }} - name: A job to run test FreeBSD + name: FreeBSD env: MYTOKEN : ${{ secrets.MYTOKEN }} MYTOKEN2: "value2" diff --git a/run.sh b/run.sh index 23697c4..cdccb6e 100644 --- a/run.sh +++ b/run.sh @@ -116,7 +116,13 @@ importVM() { waitForLoginTag() { - bash $vmsh waitForText "$osname" "$VM_LOGIN_TAG" + if [ -e "hooks/waitForLoginTag.sh" ]; then + echo "Run hooks/waitForLoginTag.sh" + . hooks/waitForLoginTag.sh + else + bash $vmsh waitForText "$osname" "$VM_LOGIN_TAG" + fi + } @@ -239,7 +245,7 @@ waitForBooting() { showDebugInfo() { echo "==================Debug Info====================" pwd && ls -lah - bash -c 'pwd && ls -lah ~/.ssh/ && cat ~/.ssh/config' + bash -c 'pwd && ls -lah ~/.ssh/ && [ -e "~/.ssh/config" ] && cat ~/.ssh/config' cat $_conf_filename echo "===================Debug Info in VM============="