From 52118b4099af406ac1ef702df0718208af940834 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 11:17:53 -0800 Subject: [PATCH 01/10] sleep between xvfb and icewm --- actions/setup/action.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index b7db048e..81ba77e0 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -107,6 +107,7 @@ runs: if [ "${{ inputs.display }}" = "xvfb" ]; then Xvfb $DISPLAY -screen 0 1024x768x24 -ac +extension GLX +render -noreset & if [ "${{ inputs.window-manager }}" = "icewm" ]; then + sleep 3 icewm & fi elif [ "${{ inputs.display }}" = "turbovnc" ]; then From 52c25c6a42021ebebe30cca423ae373b90904b71 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 11:25:51 -0800 Subject: [PATCH 02/10] more sleep [no ci] --- actions/setup/action.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index 81ba77e0..553fafd2 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -107,7 +107,7 @@ runs: if [ "${{ inputs.display }}" = "xvfb" ]; then Xvfb $DISPLAY -screen 0 1024x768x24 -ac +extension GLX +render -noreset & if [ "${{ inputs.window-manager }}" = "icewm" ]; then - sleep 3 + sleep 1 icewm & fi elif [ "${{ inputs.display }}" = "turbovnc" ]; then @@ -120,6 +120,7 @@ runs: vncserver $DISPLAY -geometry 1024x768 -depth 24 fi fi + sleep 5 shell: bash - if: runner.os == 'Linux' || runner.os == 'macOS' run: | From ba00e5561c16263ced442ae2d540e2007509e57a Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:04:20 -0800 Subject: [PATCH 03/10] support fluxbox --- actions/setup/action.yaml | 13 ++++++++++--- scripts/install_ubuntu_sys_req.sh | 1 - 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index 553fafd2..b402ee06 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -101,21 +101,28 @@ runs: sudo dpkg -i turbovnc_2.2.5_amd64.deb echo "/opt/TurboVNC/bin" >> $GITHUB_PATH fi + if [ "${{ inputs.window-manager }}" = "icewm" ]; then + sudo apt-get install icewm + elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then + sudo apt-get install fluxbox + fi shell: bash - if: runner.os == 'Linux' run: | if [ "${{ inputs.display }}" = "xvfb" ]; then Xvfb $DISPLAY -screen 0 1024x768x24 -ac +extension GLX +render -noreset & + sleep 1 if [ "${{ inputs.window-manager }}" = "icewm" ]; then - sleep 1 icewm & + elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then + fluxbox & fi elif [ "${{ inputs.display }}" = "turbovnc" ]; then mkdir $HOME/.vnc echo $RANDOM$RANDOM | vncpasswd -f > $HOME/.vnc/passwd chmod 0600 $HOME/.vnc/passwd - if [ "${{ inputs.window-manager }}" = "icewm" ]; then - vncserver $DISPLAY -geometry 1024x768 -depth 24 -wm "icewm" + if [ -n "${{ inputs.window-manager }}" ]; then + vncserver $DISPLAY -geometry 1024x768 -depth 24 -wm "${{ inputs.window-manager }}" else vncserver $DISPLAY -geometry 1024x768 -depth 24 fi diff --git a/scripts/install_ubuntu_sys_req.sh b/scripts/install_ubuntu_sys_req.sh index d250219b..7f4fb8be 100644 --- a/scripts/install_ubuntu_sys_req.sh +++ b/scripts/install_ubuntu_sys_req.sh @@ -5,7 +5,6 @@ set -e apt-get update apt-get install --no-install-recommends -y \ xvfb \ - icewm \ libglib2.0-0 \ libgtk-3-0 \ psmisc \ From 52048fec0797c0f0c3ae2c6c425aa784fab089d3 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:21:13 -0800 Subject: [PATCH 04/10] use nohup --- actions/setup/action.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index b402ee06..da2881cc 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -113,9 +113,9 @@ runs: Xvfb $DISPLAY -screen 0 1024x768x24 -ac +extension GLX +render -noreset & sleep 1 if [ "${{ inputs.window-manager }}" = "icewm" ]; then - icewm & + nohup icewm & elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then - fluxbox & + nohup fluxbox & fi elif [ "${{ inputs.display }}" = "turbovnc" ]; then mkdir $HOME/.vnc From 6b82c37d5bd13d6d6c14a6e27c5ec92b18228857 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:26:30 -0800 Subject: [PATCH 05/10] support xfce --- actions/setup/action.yaml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index da2881cc..62ffc0e2 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -101,7 +101,9 @@ runs: sudo dpkg -i turbovnc_2.2.5_amd64.deb echo "/opt/TurboVNC/bin" >> $GITHUB_PATH fi - if [ "${{ inputs.window-manager }}" = "icewm" ]; then + if [ "${{ inputs.window-manager }}" = "xfce" ]; then + sudo apt-get install xfce4 xfce4-goodies + elif [ "${{ inputs.window-manager }}" = "icewm" ]; then sudo apt-get install icewm elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then sudo apt-get install fluxbox @@ -112,7 +114,9 @@ runs: if [ "${{ inputs.display }}" = "xvfb" ]; then Xvfb $DISPLAY -screen 0 1024x768x24 -ac +extension GLX +render -noreset & sleep 1 - if [ "${{ inputs.window-manager }}" = "icewm" ]; then + if [ "${{ inputs.window-manager }}" = "xfce" ]; then + nohup startxfce4 & + elif [ "${{ inputs.window-manager }}" = "icewm" ]; then nohup icewm & elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then nohup fluxbox & @@ -121,7 +125,9 @@ runs: mkdir $HOME/.vnc echo $RANDOM$RANDOM | vncpasswd -f > $HOME/.vnc/passwd chmod 0600 $HOME/.vnc/passwd - if [ -n "${{ inputs.window-manager }}" ]; then + if [ "${{ inputs.window-manager }}" = "xfce" ]; then + vncserver $DISPLAY -geometry 1024x768 -depth 24 -wm "startxfce4" + elif [ -n "${{ inputs.window-manager }}" ]; then vncserver $DISPLAY -geometry 1024x768 -depth 24 -wm "${{ inputs.window-manager }}" else vncserver $DISPLAY -geometry 1024x768 -depth 24 From 3a650db575cd131e585c88dc0be450535fb7e208 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:32:01 -0800 Subject: [PATCH 06/10] --no-install-recommends --- actions/setup/action.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index 62ffc0e2..2c7ad6be 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -102,7 +102,7 @@ runs: echo "/opt/TurboVNC/bin" >> $GITHUB_PATH fi if [ "${{ inputs.window-manager }}" = "xfce" ]; then - sudo apt-get install xfce4 xfce4-goodies + sudo apt-get install --no-install-recommends xfce4 xfce4-goodies elif [ "${{ inputs.window-manager }}" = "icewm" ]; then sudo apt-get install icewm elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then From 2adf179d4956d5965c3e7eea5a9e722c93e9ba45 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:37:54 -0800 Subject: [PATCH 07/10] add dbus-x11 --- actions/setup/action.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index 2c7ad6be..dfbd2f74 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -102,7 +102,7 @@ runs: echo "/opt/TurboVNC/bin" >> $GITHUB_PATH fi if [ "${{ inputs.window-manager }}" = "xfce" ]; then - sudo apt-get install --no-install-recommends xfce4 xfce4-goodies + sudo apt-get install --no-install-recommends xfce4 xfce4-goodies dbus-x11 elif [ "${{ inputs.window-manager }}" = "icewm" ]; then sudo apt-get install icewm elif [ "${{ inputs.window-manager }}" = "fluxbox" ]; then From 718c8167f82d7198df50e89da238a7496cecc25e Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:42:16 -0800 Subject: [PATCH 08/10] set default to fluxbox --- actions/setup/action.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index dfbd2f74..0ed47deb 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -54,7 +54,7 @@ inputs: window-manager: description: internal and experimental only required: true - default: "icewm" + default: "fluxbox" runs: using: 'composite' From 057e6129b16cace4551a68df3106ba06ab7e6c43 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:44:15 -0800 Subject: [PATCH 09/10] do not sleep --- actions/setup/action.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index 0ed47deb..09277e2a 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -133,7 +133,6 @@ runs: vncserver $DISPLAY -geometry 1024x768 -depth 24 fi fi - sleep 5 shell: bash - if: runner.os == 'Linux' || runner.os == 'macOS' run: | From 45afbe8a74107652b1f423837f48c524161c60c8 Mon Sep 17 00:00:00 2001 From: Randy Lai Date: Mon, 15 Nov 2021 14:49:02 -0800 Subject: [PATCH 10/10] move xvfb installation line --- actions/setup/action.yaml | 5 ++++- scripts/install_ubuntu_sys_req.sh | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/actions/setup/action.yaml b/actions/setup/action.yaml index 09277e2a..cc59421a 100644 --- a/actions/setup/action.yaml +++ b/actions/setup/action.yaml @@ -96,7 +96,10 @@ runs: run: | sudo bash $GITHUB_ACTION_PATH/../../scripts/install_ubuntu_sys_req.sh echo "DISPLAY=:1" >> $GITHUB_ENV - if [ "${{ inputs.display }}" = "turbovnc" ]; then + + if [ "${{ inputs.display }}" = "xvfb" ]; then + sudo apt-get install xvfb + elif [ "${{ inputs.display }}" = "turbovnc" ]; then wget https://phoenixnap.dl.sourceforge.net/project/turbovnc/2.2.5/turbovnc_2.2.5_amd64.deb sudo dpkg -i turbovnc_2.2.5_amd64.deb echo "/opt/TurboVNC/bin" >> $GITHUB_PATH diff --git a/scripts/install_ubuntu_sys_req.sh b/scripts/install_ubuntu_sys_req.sh index 7f4fb8be..81ce7299 100644 --- a/scripts/install_ubuntu_sys_req.sh +++ b/scripts/install_ubuntu_sys_req.sh @@ -4,11 +4,11 @@ set -e apt-get update apt-get install --no-install-recommends -y \ - xvfb \ libglib2.0-0 \ libgtk-3-0 \ psmisc \ - locales locales-all + locales \ + locales-all if [ "$SUBLIME_TEXT_ARCH" = "x32" ]; then