mirror of
https://github.com/MysticRyuujin/guac-install.git
synced 2023-10-10 13:36:56 +02:00
Fix for Debian Buster (#107)
* Fix for Debian Buster Validated Installation with Debian Buster 10.3.0 * Update README.md
This commit is contained in:
parent
7a059134da
commit
a312feb0b1
@ -2,17 +2,17 @@
|
|||||||
|
|
||||||
# guac-install
|
# guac-install
|
||||||
|
|
||||||
Script for installing Guacamole 1.1.0 on Ubuntu 16.04 or newer (optionally with MySQL by default). It should also work on pure Debian 7, 8, and 9. **It seems Debian 10 is not working right now**
|
Script for installing Guacamole 1.1.0 on Ubuntu 16.04 or newer (with MySQL, or remote MySQL). It should also work on pure Debian or Raspbian. I have tested this with Debian 10.3.0 (Buster). **If other versions don't work please open an issue.** It is likely due to a required library having a different name.
|
||||||
|
|
||||||
Run script, enter MySQL Root Password and Guacamole User password. Guacamole User is used to connect to the Guacamole Database.
|
Run script, enter MySQL Root Password and Guacamole User password. Guacamole User is used to connect to the Guacamole Database.
|
||||||
|
|
||||||
The script attempts to install tomcat8 if the available version is 8.5.x or newer, if tomcat8 is only 8.0.x it will fall back to tomcat7. If you want to manually specify a tomcat version there's a commented out line you can modify. Have at it.
|
The script attempts to install tomcat9 by default. It will fall back on tomcat8 **if the available version is 8.5.x or newer**, otherwise it will fall back to tomcat7. If you want to manually specify a tomcat version there's a commented out line you can modify. Have at it.
|
||||||
|
|
||||||
If you're looking to also have NGINX / Let's Encrypt / HTTPS click [HERE](https://github.com/bigredthelogger/guacamole)
|
If you're looking to also have NGINX / Let's Encrypt / HTTPS click [HERE](https://github.com/bigredthelogger/guacamole)
|
||||||
|
|
||||||
## MFA/2FA
|
## MFA/2FA
|
||||||
|
|
||||||
By default the script will not install MFA support (QR code for Google/Microsoft Authenticator, Duo Mobile, etc. or Duo Push), if you do want MFA support you need to specify the `-t` or `--totp` or for Duo `-d` or `--duo` flags on the command line. Or modify the script variables `installTOTP=true` or `installDuo=true`.
|
By default the script will not install MFA support (QR code for Google/Microsoft Authenticator, Duo Mobile, etc. or Duo Push), if you do want MFA support you need to specify the `-t` or `--totp` or for Duo `-d` or `--duo` flags on the command line. Or modify the script variables `installTOTP=true` or `installDuo=true`. **Do not install both**
|
||||||
|
|
||||||
## How to Run:
|
## How to Run:
|
||||||
|
|
||||||
@ -44,7 +44,6 @@ The default credentials are guacadmin as both username and password. Please chan
|
|||||||
# guac-upgrade
|
# guac-upgrade
|
||||||
Script for upgrading currently installed Guacamole instance (previously installed via this script/guide). This will also now update the TOTP or Duo extensions if used.
|
Script for upgrading currently installed Guacamole instance (previously installed via this script/guide). This will also now update the TOTP or Duo extensions if used.
|
||||||
|
|
||||||
|
|
||||||
If looks for the tomcat folder in /etc/ (E.G. `/etc/tomcat7` or `/etc/tomcat8`) hopefully that works to identify the correct tomcat version/path :smile: I'm open to suggestions/pull requests for a cleaner method.
|
If looks for the tomcat folder in /etc/ (E.G. `/etc/tomcat7` or `/etc/tomcat8`) hopefully that works to identify the correct tomcat version/path :smile: I'm open to suggestions/pull requests for a cleaner method.
|
||||||
|
|
||||||
## All Switches
|
## All Switches
|
||||||
|
@ -24,17 +24,15 @@ LOG="/tmp/guacamole_${GUACVERSION}_build.log"
|
|||||||
# Initialize variable values
|
# Initialize variable values
|
||||||
installTOTP=""
|
installTOTP=""
|
||||||
installDuo=""
|
installDuo=""
|
||||||
|
|
||||||
installMySQL=""
|
installMySQL=""
|
||||||
mysqlHost=""
|
mysqlHost=""
|
||||||
mysqlPort=""
|
mysqlPort=""
|
||||||
mysqlRootPwd=""
|
mysqlRootPwd=""
|
||||||
|
|
||||||
guacDb=""
|
guacDb=""
|
||||||
guacUser=""
|
guacUser=""
|
||||||
guacPwd=""
|
guacPwd=""
|
||||||
|
|
||||||
PROMPT=""
|
PROMPT=""
|
||||||
|
MYSQL=""
|
||||||
|
|
||||||
# Get script arguments for non-interactive mode
|
# Get script arguments for non-interactive mode
|
||||||
while [ "$1" != "" ]; do
|
while [ "$1" != "" ]; do
|
||||||
@ -97,6 +95,7 @@ if [[ -z $installTOTP ]] && [[ -z $installDuo ]]; then
|
|||||||
read PROMPT
|
read PROMPT
|
||||||
if [[ $PROMPT =~ ^[Yy]$ ]]; then
|
if [[ $PROMPT =~ ^[Yy]$ ]]; then
|
||||||
installTOTP=true
|
installTOTP=true
|
||||||
|
installDuo=false
|
||||||
else
|
else
|
||||||
installTOTP=false
|
installTOTP=false
|
||||||
fi
|
fi
|
||||||
@ -108,6 +107,7 @@ if [[ -z $installDuo ]] && [[ -z $installTOTP ]]; then
|
|||||||
read PROMPT
|
read PROMPT
|
||||||
if [[ $PROMPT =~ ^[Yy]$ ]]; then
|
if [[ $PROMPT =~ ^[Yy]$ ]]; then
|
||||||
installDuo=true
|
installDuo=true
|
||||||
|
installTOTP=false
|
||||||
else
|
else
|
||||||
installDuo=false
|
installDuo=false
|
||||||
fi
|
fi
|
||||||
@ -197,6 +197,11 @@ if [[ "${NAME}" == "Ubuntu" ]]; then
|
|||||||
else
|
else
|
||||||
LIBPNG="libpng-dev"
|
LIBPNG="libpng-dev"
|
||||||
fi
|
fi
|
||||||
|
if [ "$installMySQL" = true ]; then
|
||||||
|
MYSQL="mysql-server mysql-client mysql-common mysql-utilities"
|
||||||
|
else
|
||||||
|
MYSQL="mysql-client"
|
||||||
|
fi
|
||||||
elif [[ "${NAME}" == *"Debian"* ]] || [[ "${NAME}" == *"Raspbian GNU/Linux"* ]]; then
|
elif [[ "${NAME}" == *"Debian"* ]] || [[ "${NAME}" == *"Raspbian GNU/Linux"* ]]; then
|
||||||
JPEGTURBO="libjpeg62-turbo-dev"
|
JPEGTURBO="libjpeg62-turbo-dev"
|
||||||
if [[ "${PRETTY_NAME}" == *"stretch"* ]] || [[ "${PRETTY_NAME}" == *"buster"* ]]; then
|
if [[ "${PRETTY_NAME}" == *"stretch"* ]] || [[ "${PRETTY_NAME}" == *"buster"* ]]; then
|
||||||
@ -204,6 +209,11 @@ elif [[ "${NAME}" == *"Debian"* ]] || [[ "${NAME}" == *"Raspbian GNU/Linux"* ]];
|
|||||||
else
|
else
|
||||||
LIBPNG="libpng12-dev"
|
LIBPNG="libpng12-dev"
|
||||||
fi
|
fi
|
||||||
|
if [ "$installMySQL" = true ]; then
|
||||||
|
MYSQL="default-mysql-server default-mysql-client mysql-common"
|
||||||
|
else
|
||||||
|
MYSQL="default-mysql-client"
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
echo "Unsupported Distro - Ubuntu, Debian, or Raspbian Only"
|
echo "Unsupported Distro - Ubuntu, Debian, or Raspbian Only"
|
||||||
exit 1
|
exit 1
|
||||||
@ -232,15 +242,6 @@ else
|
|||||||
TOMCAT="tomcat7"
|
TOMCAT="tomcat7"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
MYSQL=""
|
|
||||||
if [ "$installMySQL" = true ]; then
|
|
||||||
if [ -z $(command -v mysql) ]; then
|
|
||||||
MYSQL="mysql-server mysql-client mysql-common mysql-utilities"
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
MYSQL="mysql-client"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Uncomment to manually force a tomcat version
|
# Uncomment to manually force a tomcat version
|
||||||
#TOMCAT=""
|
#TOMCAT=""
|
||||||
|
|
||||||
@ -271,6 +272,8 @@ if [ $? -ne 0 ]; then
|
|||||||
echo -e "${RED}Failed to download guacamole-server-${GUACVERSION}.tar.gz"
|
echo -e "${RED}Failed to download guacamole-server-${GUACVERSION}.tar.gz"
|
||||||
echo -e "${SERVER}/source/guacamole-server-${GUACVERSION}.tar.gz${NC}"
|
echo -e "${SERVER}/source/guacamole-server-${GUACVERSION}.tar.gz${NC}"
|
||||||
exit 1
|
exit 1
|
||||||
|
else
|
||||||
|
tar -xzf guacamole-server-${GUACVERSION}.tar.gz
|
||||||
fi
|
fi
|
||||||
echo -e "${GREEN}Downloaded guacamole-server-${GUACVERSION}.tar.gz${NC}"
|
echo -e "${GREEN}Downloaded guacamole-server-${GUACVERSION}.tar.gz${NC}"
|
||||||
|
|
||||||
@ -289,6 +292,8 @@ if [ $? -ne 0 ]; then
|
|||||||
echo -e "${RED}Failed to download guacamole-auth-jdbc-${GUACVERSION}.tar.gz"
|
echo -e "${RED}Failed to download guacamole-auth-jdbc-${GUACVERSION}.tar.gz"
|
||||||
echo -e "${SERVER}/binary/guacamole-auth-jdbc-${GUACVERSION}.tar.gz"
|
echo -e "${SERVER}/binary/guacamole-auth-jdbc-${GUACVERSION}.tar.gz"
|
||||||
exit 1
|
exit 1
|
||||||
|
else
|
||||||
|
tar -xzf guacamole-auth-jdbc-${GUACVERSION}.tar.gz
|
||||||
fi
|
fi
|
||||||
echo -e "${GREEN}Downloaded guacamole-auth-jdbc-${GUACVERSION}.tar.gz${NC}"
|
echo -e "${GREEN}Downloaded guacamole-auth-jdbc-${GUACVERSION}.tar.gz${NC}"
|
||||||
|
|
||||||
@ -301,9 +306,10 @@ if [ "$installTOTP" = true ]; then
|
|||||||
echo -e "${RED}Failed to download guacamole-auth-totp-${GUACVERSION}.tar.gz"
|
echo -e "${RED}Failed to download guacamole-auth-totp-${GUACVERSION}.tar.gz"
|
||||||
echo -e "${SERVER}/binary/guacamole-auth-totp-${GUACVERSION}.tar.gz"
|
echo -e "${SERVER}/binary/guacamole-auth-totp-${GUACVERSION}.tar.gz"
|
||||||
exit 1
|
exit 1
|
||||||
|
else
|
||||||
|
tar -xzf guacamole-auth-totp-${GUACVERSION}.tar.gz
|
||||||
fi
|
fi
|
||||||
echo -e "${GREEN}Downloaded guacamole-auth-totp-${GUACVERSION}.tar.gz${NC}"
|
echo -e "${GREEN}Downloaded guacamole-auth-totp-${GUACVERSION}.tar.gz${NC}"
|
||||||
tar -xzf guacamole-auth-totp-${GUACVERSION}.tar.gz
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Duo
|
# Duo
|
||||||
@ -313,9 +319,10 @@ if [ "$installDuo" = true ]; then
|
|||||||
echo -e "${RED}Failed to download guacamole-auth-duo-${GUACVERSION}.tar.gz"
|
echo -e "${RED}Failed to download guacamole-auth-duo-${GUACVERSION}.tar.gz"
|
||||||
echo -e "${SERVER}/binary/guacamole-auth-duo-${GUACVERSION}.tar.gz"
|
echo -e "${SERVER}/binary/guacamole-auth-duo-${GUACVERSION}.tar.gz"
|
||||||
exit 1
|
exit 1
|
||||||
|
else
|
||||||
|
tar -xzf guacamole-auth-duo-${GUACVERSION}.tar.gz
|
||||||
fi
|
fi
|
||||||
echo -e "${GREEN}Downloaded guacamole-auth-duo-${GUACVERSION}.tar.gz${NC}"
|
echo -e "${GREEN}Downloaded guacamole-auth-duo-${GUACVERSION}.tar.gz${NC}"
|
||||||
tar -xzf guacamole-auth-duo-${GUACVERSION}.tar.gz
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Deal with Missing MySQL Connector/J
|
# Deal with Missing MySQL Connector/J
|
||||||
@ -326,17 +333,14 @@ if [[ -z $JAVALIB ]]; then
|
|||||||
echo -e "${RED}Failed to download mysql-connector-java-${MCJVER}.tar.gz"
|
echo -e "${RED}Failed to download mysql-connector-java-${MCJVER}.tar.gz"
|
||||||
echo -e "https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-${MCJVER}.tar.gz${NC}"
|
echo -e "https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-${MCJVER}.tar.gz${NC}"
|
||||||
exit 1
|
exit 1
|
||||||
|
else
|
||||||
|
tar -xzf mysql-connector-java-${MCJVER}.tar.gz
|
||||||
fi
|
fi
|
||||||
echo -e "${GREEN}Downloaded mysql-connector-java-${MCJVER}.tar.gz${NC}"
|
echo -e "${GREEN}Downloaded mysql-connector-java-${MCJVER}.tar.gz${NC}"
|
||||||
tar -xzf mysql-connector-java-${MCJVER}.tar.gz
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "${GREEN}Downloading complete.${NC}"
|
echo -e "${GREEN}Downloading complete.${NC}"
|
||||||
|
|
||||||
# Extract Guacamole files
|
|
||||||
tar -xzf guacamole-server-${GUACVERSION}.tar.gz
|
|
||||||
tar -xzf guacamole-auth-jdbc-${GUACVERSION}.tar.gz
|
|
||||||
|
|
||||||
# Make directories
|
# Make directories
|
||||||
mkdir -p /etc/guacamole/lib
|
mkdir -p /etc/guacamole/lib
|
||||||
mkdir -p /etc/guacamole/extensions
|
mkdir -p /etc/guacamole/extensions
|
||||||
|
Loading…
Reference in New Issue
Block a user