Skip to content

Commit f1b35a7

Browse files
committed
Re-fix issue #16
1 parent d1dad85 commit f1b35a7

File tree

7 files changed

+62
-45
lines changed

7 files changed

+62
-45
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ Ubuntu | guacamole:1.5.2 <br> guacamole:latest | guacamole:1.5.2-pg14 <br> guaca
1717
Alpine | N/A | guacamole:1.5.2-alpine | guacamole:1.5.2-alpine-pg15
1818

1919
# What's new / Changelog
20+
**2023-06-14** - Ok, my previous fix for issue #16 did not work at all. Also, I noticed that if you enabled an extension and then tried to disable it, it would not work. That last bug went unoticed since I forked Oznu's image and started working on it!
21+
2022
**2023-06-12** - Updated to Tomcat 9.0.76
2123

2224
**2023-06-07** - :warning: It seems that Guacamole 1.5.2 [can segfault on some RDP connections](https://lists.apache.org/thread/ws7xykpm2cmnz2w42y9qy8kkn6hdpr0x). If you encounter that bug, please hold on for a bit until the Guacamole Team fixes it (and that will probably not take long).
Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
#!/usr/bin/with-contenv sh
22

33
# this one should work better and is a one liner. However, all extensions must contain the correct guacamole version in their name
4-
ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
4+
echo "Cleaning Extensions from previous Guacamole versions"
5+
for e in $(ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER}); do
6+
rm ${GUACAMOLE_HOME}/extensions/${e}
7+
done
58

6-
# this creates an issue with auth-jdbc, that is a mandatory extension, does not exist in extensions-available, and is not removed when version is bumped
7-
# clean up extensions
8-
# for i in auth-ldap auth-duo auth-header auth-cas auth-openid auth-quickconnect auth-totp auth-saml auth-json branding; do
9-
# rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
10-
#done
9+
echo "Cleaning Extensions"
10+
for i in auth-duo auth-header auth-json auth-ldap auth-quickconnect auth-sso-cas auth-sso-openid auth-sso-saml auth-totp branding history-recording-storage vault-ksm; do
11+
rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
12+
done
1113

1214
# this was from Oznu's image
1315
# if the guacamole version was bumped, delete the contents of the extensions directory - just on the first run
@@ -16,6 +18,7 @@ ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
1618
#fi
1719

1820
# enable extensions
21+
echo "Enabling selected Extensions"
1922
for i in $(echo "$EXTENSIONS" | tr "," " "); do
2023
cp ${GUACAMOLE_HOME}/extensions-available/guacamole-${i}-${GUAC_VER}.jar ${GUACAMOLE_HOME}/extensions
2124
done
Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
#!/usr/bin/with-contenv sh
22

33
# this one should work better and is a one liner. However, all extensions must contain the correct guacamole version in their name
4-
ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
4+
echo "Cleaning Extensions from previous Guacamole versions"
5+
for e in $(ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER}); do
6+
rm ${GUACAMOLE_HOME}/extensions/${e}
7+
done
58

6-
# this creates an issue with auth-jdbc, that is a mandatory extension, does not exist in extensions-available, and is not removed when version is bumped
7-
# clean up extensions
8-
# for i in auth-ldap auth-duo auth-header auth-cas auth-openid auth-quickconnect auth-totp auth-saml auth-json branding; do
9-
# rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
10-
#done
9+
echo "Cleaning Extensions"
10+
for i in auth-duo auth-header auth-json auth-ldap auth-quickconnect auth-sso-cas auth-sso-openid auth-sso-saml auth-totp branding history-recording-storage vault-ksm; do
11+
rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
12+
done
1113

1214
# this was from Oznu's image
1315
# if the guacamole version was bumped, delete the contents of the extensions directory - just on the first run
@@ -16,6 +18,7 @@ ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
1618
#fi
1719

1820
# enable extensions
21+
echo "Enabling selected Extensions"
1922
for i in $(echo "$EXTENSIONS" | tr "," " "); do
2023
cp ${GUACAMOLE_HOME}/extensions-available/guacamole-${i}-${GUAC_VER}.jar ${GUACAMOLE_HOME}/extensions
2124
done
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
#!/usr/bin/with-contenv sh
22

33
# this one should work better and is a one liner. However, all extensions must contain the correct guacamole version in their name
4-
ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
4+
echo "Cleaning Extensions from previous Guacamole versions"
5+
for e in $(ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER}); do
6+
rm ${GUACAMOLE_HOME}/extensions/${e}
7+
done
58

6-
# this creates an issue with auth-jdbc, that is a mandatory extension, does not exist in extensions-available, and is not removed when version is bumped
7-
# clean up extensions
8-
# for i in auth-ldap auth-duo auth-header auth-cas auth-openid auth-quickconnect auth-totp auth-saml auth-json branding; do
9-
# rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
10-
#done
9+
echo "Cleaning Extensions"
10+
for i in auth-duo auth-header auth-json auth-ldap auth-quickconnect auth-sso-cas auth-sso-openid auth-sso-saml auth-totp branding history-recording-storage vault-ksm; do
11+
rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
12+
done
1113

1214
# this was from Oznu's image
1315
# if the guacamole version was bumped, delete the contents of the extensions directory - just on the first run
@@ -16,6 +18,7 @@ ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
1618
#fi
1719

1820
# enable extensions
21+
echo "Enabling selected Extensions"
1922
for i in $(echo "$EXTENSIONS" | tr "," " "); do
2023
cp ${GUACAMOLE_HOME}/extensions-available/guacamole-${i}-${GUAC_VER}.jar ${GUACAMOLE_HOME}/extensions
2124
done
Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
11
#!/usr/bin/with-contenv sh
22

33
# this one should work better and is a one liner. However, all extensions must contain the correct guacamole version in their name
4-
ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
4+
echo "Cleaning Extensions from previous Guacamole versions"
5+
for e in $(ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER}); do
6+
rm ${GUACAMOLE_HOME}/extensions/${e}
7+
done
58

6-
# this creates an issue with auth-jdbc, that is a mandatory extension, does not exist in extensions-available, and is not removed when version is bumped
7-
# clean up extensions
8-
# for i in auth-ldap auth-duo auth-header auth-cas auth-openid auth-quickconnect auth-totp auth-saml auth-json branding; do
9-
# rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
10-
#done
9+
echo "Cleaning Extensions"
10+
for i in auth-duo auth-header auth-json auth-ldap auth-quickconnect auth-sso-cas auth-sso-openid auth-sso-saml auth-totp branding history-recording-storage vault-ksm; do
11+
rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
12+
done
1113

1214
# this was from Oznu's image
1315
# if the guacamole version was bumped, delete the contents of the extensions directory - just on the first run
@@ -16,6 +18,7 @@ ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER} | xargs rm -f
1618
#fi
1719

1820
# enable extensions
21+
echo "Enabling selected Extensions"
1922
for i in $(echo "$EXTENSIONS" | tr "," " "); do
2023
cp ${GUACAMOLE_HOME}/extensions-available/guacamole-${i}-${GUAC_VER}.jar ${GUACAMOLE_HOME}/extensions
2124
done

root_pg15/etc/cont-init.d/50-extensions

Lines changed: 0 additions & 21 deletions
This file was deleted.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/usr/bin/with-contenv sh
2+
3+
# this one should work better and is a one liner. However, all extensions must contain the correct guacamole version in their name
4+
echo "Cleaning Extensions from previous Guacamole versions"
5+
for e in $(ls -1 ${GUACAMOLE_HOME}/extensions | grep -v ${GUAC_VER}); do
6+
rm ${GUACAMOLE_HOME}/extensions/${e}
7+
done
8+
9+
echo "Cleaning Extensions"
10+
for i in auth-duo auth-header auth-json auth-ldap auth-quickconnect auth-sso-cas auth-sso-openid auth-sso-saml auth-totp branding history-recording-storage vault-ksm; do
11+
rm -rf ${GUACAMOLE_HOME}/extensions/guacamole-${i}-${GUAC_VER}.jar
12+
done
13+
14+
# this was from Oznu's image
15+
# if the guacamole version was bumped, delete the contents of the extensions directory - just on the first run
16+
#if [ "$(cat /config/.database-version)" != "$GUAC_VER" ]; then
17+
# rm -rf ${GUACAMOLE_HOME}/extensions/*
18+
#fi
19+
20+
# enable extensions
21+
echo "Enabling selected Extensions"
22+
for i in $(echo "$EXTENSIONS" | tr "," " "); do
23+
cp ${GUACAMOLE_HOME}/extensions-available/guacamole-${i}-${GUAC_VER}.jar ${GUACAMOLE_HOME}/extensions
24+
done

0 commit comments

Comments
 (0)