Apache Guacamole
Overview
Apache Guacamole is a clientless HTML5 remote-desktop gateway. It lets you reach RDP, VNC and SSH machines from a web browser, with nothing to install on the client.
This image gives you Guacamole 1.6.0 ready to use on Azure. It generates a unique administrator password on the first boot of every VM and is backed by 24/7 SecureAnyCloud support.
What you get:
- Apache Guacamole 1.6.0 web application (
guacamole.war) under Tomcat 9 - The native
guacdproxy daemon with the RDP, VNC and SSH protocol clients - PostgreSQL authentication and connection storage via the JDBC auth extension
- A dedicated Azure data disk at
/var/lib/postgresqlthat holds all users and connections. It is separate from the OS disk and re-provisioned with every VM. - An nginx reverse proxy on
:80with the WebSocket headers the Guacamole tunnel requires - A per-VM
guacadminpassword generated at first boot, in a root-only file guacd.service,tomcat9.service,postgresql.serviceandnginx.serviceas systemd units, enabled and active- 24/7 SecureAnyCloud support
Prerequisites
You need an active Azure subscription, an SSH key pair, and a VNet and subnet in the target region.
Standard_B2ms (2 vCPU / 8 GiB RAM) is a good starting point, because Tomcat's JVM, PostgreSQL and guacd run together on the VM.
For the NSG, allow 22/tcp inbound from your management network. Allow 80/tcp from the users who connect to the gateway. For public exposure, front port 80 with TLS (see Enabling HTTPS).
Step 1 - Deploy from the Azure Marketplace
Sign in to the Azure Portal, choose Create a resource, and search the Marketplace for Apache Guacamole by SecureAnyCloud. Select Create.
On Basics, pick your subscription, resource group, region and size. Under Administrator account, choose SSH public key and paste your key. Under Inbound port rules, allow SSH (22) and HTTP (80).
Review the dedicated data disk on the Disks tab. Then choose Review + create and Create.
Step 2 - Deploy from the Azure CLI
Accept the Marketplace terms once, then create the VM and open port 80:
# Accept the Marketplace terms once per subscription (required before the first CLI deploy)
az vm image terms accept --urn sac1647283583153:apache-guacamole-ubuntu-24-04:default:latest
az vm create \
--resource-group <your-rg> \
--name guacamole \
--image sac1647283583153:apache-guacamole-ubuntu-24-04:default:latest \
--size Standard_B2ms \
--admin-username azureuser \
--ssh-key-values ~/.ssh/id_ed25519.pub \
--vnet-name <your-vnet> --subnet <your-subnet> \
--public-ip-sku Standard
az vm open-port --resource-group <your-rg> --name guacamole --port 80 --priority 1010Step 3 - Connect to your VM
Connect over SSH with the public IP address of the VM:
ssh azureuser@<vm-public-ip>Step 4 - Confirm the services are running
Check that all four services are active:
systemctl is-active guacd.service tomcat9.service postgresql.service nginx.serviceAll four services report active.
Step 5 - Confirm the web gateway answers
Request the gateway from the VM itself:
curl -s -o /dev/null -w 'guacamole web UI -> HTTP %{http_code}\n' http://127.0.0.1/The nginx reverse proxy fronts the Tomcat web application and returns HTTP 200 (the login page).
Step 6 - Retrieve your admin password
The first boot of your VM generates a unique administrator password and writes it to a root-only file. Read it with:
sudo grep -E '^GUACAMOLE_' /root/guacamole-credentials.txtGUACAMOLE_ADMIN_USER is guacadmin and GUACAMOLE_ADMIN_PASSWORD is the password.
Step 7 - Verify the login REST API
Guacamole issues an auth token from POST /api/tokens. The following commands read the per-VM password. They show that a wrong password is rejected and that the real one returns a token:
PW=$(sudo grep '^GUACAMOLE_ADMIN_PASSWORD=' /root/guacamole-credentials.txt | cut -d= -f2-)
echo "wrong password -> HTTP $(curl -s -o /dev/null -w '%{http_code}' --data-urlencode 'username=guacadmin' --data-urlencode 'password=wrong' http://127.0.0.1/api/tokens)" curl -s --data-urlencode 'username=guacadmin' --data-urlencode "password=$PW" http://127.0.0.1/api/tokens | head -c 80; echoThe wrong password returns HTTP 403. The correct one returns a JSON document that contains an authToken.
Step 8 - Sign in to the web UI
Open http://<vm-public-ip>/ in a browser. Sign in as guacadmin with the password from Step 6.
After you sign in, you land on the home screen, which lists your recent and available connections.
Step 9 - Add a remote-desktop connection
Open the user menu (top right), then choose Settings, Connections and New Connection. Choose the protocol (RDP, VNC or SSH) and give the connection a name. Fill in the target host, port and credentials, then choose Save.
The connection appears on the home screen, where any authorised user can launch it in their browser.
Confirm the Guacamole version
Check that the Guacamole web application is deployed:
sudo ls /opt/tomcat/webapps/guacamole.war && echo "Apache Guacamole 1.6.0 deployed"Enabling HTTPS
For production, terminate TLS at nginx with a real domain that points at the VM's public IP. Install certbot and request a certificate, replacing the domain with your own:
sudo apt-get update && sudo apt-get install -y certbot python3-certbot-nginx
sudo certbot --nginx -d your-domain.example.comBackup and maintenance
All Guacamole data (users, connection definitions and permissions) lives in PostgreSQL on the dedicated data disk at /var/lib/postgresql. Snapshot that disk in Azure to back up your configuration.
Keep the OS patched with sudo apt update && sudo apt upgrade. The gateway restarts cleanly with sudo systemctl restart guacd tomcat9 nginx.
Support
This image is backed by 24/7 SecureAnyCloud support. Contact us by email or chat for help with RDP, VNC and SSH connection setup, user and permission management, scaling, TLS and backups.
All product and company names are trademarks or registered trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by them.
Deploy on Azure
Launch Apache Guacamole on Ubuntu 24.04 LTS on Azure with 24/7 support from SecureAnyCloud.
View this image
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com
Overview
Apache Guacamole is an open source, clientless remote-desktop gateway. It lets you reach Windows machines over RDP, Linux and network devices over SSH or Telnet, and any desktop over VNC, entirely from a web browser. There is no client software or browser plugin to install, so any device with a modern browser becomes a remote-desktop client.
This image gives you Apache Guacamole 1.6.0, preconfigured and secure by default, on AWS. It generates a fresh administrator password on the first boot of every instance and is backed by 24/7 SecureAnyCloud support.
What you get:
- guacd, the native proxy daemon that speaks RDP, VNC, SSH and Telnet and relays them to the browser over a WebSocket tunnel. It is compiled from the official Apache source release, runs under systemd and listens only on the loopback interface.
- The Guacamole web application (
guacamole.war) running inside Apache Tomcat 9, installed from the official Apache archive. The application targets thejavax.servletAPI, which is why it runs on Tomcat 9. - User, connection and permission storage in a MariaDB database through Guacamole's official JDBC extension, all managed from the web interface
- An nginx reverse proxy that publishes the portal on port 80 and forwards to Tomcat on the loopback interface. It adds the WebSocket upgrade headers the remote-desktop tunnel requires.
- Dedicated EBS data volumes for the
GUACAMOLE_HOMEconfiguration tree and for the MariaDB data directory, separate from the operating system disk, so you can resize each tier independently of the root volume
The JDBC schema seeds a single administrator named guacadmin. On the first boot of every deployed instance, a one-shot service generates a fresh administrator password and a fresh MariaDB password, both unique to that instance. It rewrites the database credential in lock step and writes the administrator user name and password to a root-only file.
Two instances launched from the same Amazon Machine Image never share a password. The well-known default guacadmin / guacadmin login never works on a deployed instance.
Prerequisites
Before you deploy this image, you need:
- An Amazon Web Services account where you can launch EC2 instances
- IAM permissions to launch instances, create security groups and subscribe to AWS Marketplace products
- An EC2 key pair in the target Region for SSH access to the instance
- A VPC and subnet in the target Region, with a security group that allows inbound port 22 from your management network. The group must also allow inbound port 80 from the trusted networks that will reach the Guacamole portal, and optionally port 443 if you enable HTTPS as described later.
- The AWS CLI (version 2) installed locally, if you plan to deploy from the command line
Launch the instance from the AWS Marketplace
Sign in to the AWS Management Console, open the EC2 service, and choose Launch instance. Under Application and OS Images, choose AWS Marketplace AMIs and search for Apache Guacamole. Select the SecureAnyCloud listing and choose Select, then choose Continue on the subscription summary.
Pick an instance type of m5.large or larger. Guacamole runs a Java servlet container, a native proxy daemon and a database, and the remote-desktop sessions it proxies benefit from memory and network throughput. Choose your EC2 key pair under Key pair (login).
Under Network settings, select your VPC and subnet. Create or select a security group that allows inbound port 22 from your management network and inbound port 80 from the trusted networks that will reach the portal. Do not open these ports to the public internet unless you intend the portal to be publicly reachable. Leave the root volume at the default size or larger. The configuration and database volumes are attached automatically.
Choose Launch instance. First-boot initialisation takes approximately one to two minutes after the instance state becomes Running and the status checks pass. During that time the first-boot service generates the credentials and the services start.
Launch the instance from the AWS CLI
The following command launches an instance from the SecureAnyCloud Apache Guacamole Marketplace AMI into an existing subnet and security group. Replace <ami-id> with the AMI ID shown on the Marketplace listing. Replace <key-name> with your EC2 key pair name and <subnet-id> with your subnet ID. Replace <security-group-id> with a security group that opens ports 22 and 80, and optionally 443, as described above.
aws ec2 run-instances \
--image-id <ami-id> \
--instance-type m5.large \
--key-name <key-name> \
--subnet-id <subnet-id> \
--security-group-ids <security-group-id> \
--block-device-mappings '[{"DeviceName":"/dev/sda1","Ebs":{"VolumeSize":30,"VolumeType":"gp3"}}]' \
--tag-specifications 'ResourceType=instance,Tags=[{Key=Name,Value=guacamole-01}]'On success, the command prints a JSON document. Note the instance ID. Once the instance is running, retrieve its public address with aws ec2 describe-instances --instance-ids <instance-id> --query "Reservations[].Instances[].PublicIpAddress" --output text.
Connect and retrieve the administrator credentials
Connect over SSH with the key pair you selected and the public IP address from the previous step. The SSH login user depends on the operating system of the AMI variant you launched. For Apache Guacamole on Ubuntu 24.04, the login user is ubuntu.
The first-boot service runs before the SSH daemon becomes ready, so the credentials file is always in place when you log in for the first time.
ssh <login-user>@<public-ip>
sudo cat /root/apache-guacamole-credentials.txtThe file is plain text. It contains the Guacamole portal URL, the administrator user name (guacadmin) and the generated administrator password, along with the database name and credentials. Copy these values somewhere secure, such as a password manager or an encrypted vault. Do not commit them to source control.
Confirm that root owns the credentials file and that only root can read it:
sudo ls -l /root/apache-guacamole-credentials.txt-rw------- 1 root root 596 Jun 18 10:44 /root/apache-guacamole-credentials.txtVerify the server is healthy
Check that guacd, Tomcat, nginx, MariaDB and the first-boot service all report active:
for u in guacd tomcat nginx mariadb guacamole-firstboot; do printf "%s: " "$u"; systemctl is-active "$u"; doneguacd: active tomcat: active nginx: active mariadb: active guacamole-firstboot: activeCheck the deployed components. They are guacd 1.6.0, the OpenJDK 21 runtime, and Apache Tomcat 9, which the Guacamole web application requires:
guacd -v java -versionGuacamole proxy daemon (guacd) version 1.6.0 openjdk version "21.0.11" 2026-04-21Check the listening ports. nginx listens on port 80 and forwards to the Guacamole web application on Tomcat, which is bound to port 8080. guacd listens on the loopback interface on port 4822, and MariaDB on the loopback interface on port 3306. Neither the proxy nor the database is exposed off the instance:
sudo ss -tlnp | grep -E ':80 |:8080 |:4822 |:3306 'LISTEN 0 511 0.0.0.0:80 0.0.0.0:* LISTEN 0 80 127.0.0.1:3306 0.0.0.0:* LISTEN 0 4096 127.0.0.1:4822 0.0.0.0:* LISTEN 0 100 *:8080 *:*Run a quick health check to confirm that nginx serves the Guacamole web application:
curl -s -o /dev/null -w "%{http_code}\n" http://127.0.0.1/guacamole/200Open the Guacamole portal
Browse to http://<public-ip>/ from a machine on a network that the security group allows. The root path redirects to the Guacamole portal at /guacamole/. Sign in as the guacadmin user with the password from the credentials file.
After you sign in, Guacamole shows the home screen. This is a fresh instance with no connections defined, so the home screen lists no recent or available connections. You add your first connection in the next step. The user menu in the top right shows the signed-in administrator.
To reach the portal over an encrypted connection, enable HTTPS by following the Let's Encrypt section later in this guide.
Add your first connection
You manage Guacamole connections from the administration settings. From the user menu in the top right, choose Settings. Open the Connections tab and choose New Connection.
Give the connection a name, then choose the Protocol. Use RDP for a Windows machine, SSH or Telnet for a Linux host or network device, and VNC for any desktop running a VNC server.
Fill in the Network parameters for the target. At a minimum, enter the hostname or IP address and the port (3389 for RDP, 22 for SSH, 5900 for VNC, 23 for Telnet). Add any authentication parameters, such as a username and password for the target. Save the connection.
Return to the home screen and select the connection you just created. Guacamole opens the remote-desktop or terminal session in the browser tab, tunnelled through guacd. You can use clipboard integration, file transfer (for RDP and SSH) and on-screen scaling. To end the session, open the Guacamole menu with the keyboard shortcut shown on the connection screen.
Manage users and permissions
Guacamole stores users, groups, connections and permissions in the MariaDB database, and you manage them all from the web interface. Open Settings and the Users tab to add users, set their passwords and grant them access to specific connections. The administrator created on first boot, guacadmin, has full administrative rights.
Create a dedicated, non-administrative user for each person who needs remote access. Grant each user only the connections they require, and reserve the guacadmin account for administration.
Guacamole also supports LDAP and SAML single sign-on and TOTP two-factor authentication through additional extensions. Contact SecureAnyCloud support for help wiring these into this image.
Filesystem and service layout
The Guacamole configuration tree, GUACAMOLE_HOME, is /etc/guacamole, a symbolic link to /opt/guacamole on a dedicated data volume. It holds guacamole.properties, which points the web application at the database and at guacd. It also holds the JDBC authentication extension, the MariaDB Connector/J driver, and the session recording and drawing directories. List them with:
ls -la /etc/guacamole/
ls /opt/guacamole/extensions/ /opt/guacamole/lib/drwxr-xr-x 2 tomcat tomcat 4096 drawings drwxr-xr-x 2 tomcat tomcat 4096 extensions -rw-r----- 1 root tomcat 508 guacamole.properties drwxr-xr-x 2 tomcat tomcat 4096 lib drwxr-xr-x 2 tomcat tomcat 4096 recordings guacamole-auth-jdbc-mysql-1.6.0.jar mariadb-java-client.jarThe configuration tree on /opt/guacamole and the MariaDB data directory on /var/lib/mysql are each mounted on their own dedicated EBS volume. Both are separate from the operating system disk, so you can resize the configuration and database tiers independently. Confirm the mounts with:
df -h /var/lib/mysql /opt/guacamoleFilesystem Size Used Avail Use% Mounted on /dev/nvme1n1 20G 127M 19G 1% /var/lib/mysql /dev/nvme2n1 20G 12M 19G 1% /opt/guacamoleThe web application itself, guacamole.war, is deployed under Apache Tomcat in /opt/tomcat, and guacd is installed under /usr/local.
Start, stop and check status
Manage the four services with systemctl. guacd is the protocol proxy, tomcat runs the Guacamole web application, nginx is the reverse proxy on port 80, and mariadb is the database:
sudo systemctl status guacd
sudo systemctl restart tomcat
sudo systemctl restart nginxIf you change guacamole.properties or add an extension under /opt/guacamole/extensions, restart tomcat so the web application picks up the change.
Rotate the administrator password
You can change the administrator password generated on first boot at any time from the web interface. Sign in as guacadmin and open the user menu in the top right. Choose Settings, open the Preferences tab and use the Change Password form. Guacamole updates the salted password hash in the database immediately, and the old password stops working.
If you are locked out, you can also reset the password from the command line. Contact SecureAnyCloud support for the supported database procedure. It rewrites the salted SHA-256 hash that Guacamole stores in the guacamole_user table.
Enable HTTPS with Let's Encrypt
Out of the box, nginx serves the portal over plain HTTP on port 80. To serve it over HTTPS with a trusted certificate, point a DNS name at the instance and open port 443 in the security group. Then install a Let's Encrypt certificate with certbot:
sudo apt-get update
sudo apt-get install -y certbot python3-certbot-nginx
sudo certbot --nginx -d your-domain.example.comcertbot obtains the certificate, edits the nginx server block to listen on 443 with the certificate installed, and sets up automatic renewal. After it completes, the portal is reachable over HTTPS at your domain. You can also configure nginx to redirect plain HTTP to HTTPS.
Back up and maintain the instance
Back up two things. The MariaDB database holds every user, connection and permission. The GUACAMOLE_HOME tree holds the configuration and extensions. Snapshot the two EBS data volumes on a schedule, and dump the database for a portable backup:
sudo mysqldump --single-transaction guacamole_db | gzip > guacamole_db-$(date +%F).sql.gzKeep the operating system patched with sudo apt-get update && sudo apt-get upgrade. Restart tomcat after you apply Java or Guacamole updates.
The data tiers are on dedicated volumes. You can grow them with an EBS volume modification and an online filesystem resize, without touching the root volume.
Security recommendations
- Restrict the security group so that port 22 is reachable only from your management network, and port 80 (or 443) only from the networks that need the portal.
- Enable HTTPS as described in step 11, so credentials and session traffic are encrypted in transit.
- Create a dedicated, non-administrative Guacamole user for each person and grant least privilege on connections. Reserve
guacadminfor administration. - Rotate the administrator password from the Preferences page after your first sign-in, and store it in a password manager.
- Consider enabling TOTP two-factor authentication or LDAP/SAML single sign-on for the portal.
- Keep the operating system, Tomcat and Guacamole patched.
Screenshots
The Apache Guacamole sign-in page, served on port 80 through the nginx reverse proxy:
The Guacamole home screen, where signed-in users select the RDP, SSH, VNC and Telnet connections available to them:
The Guacamole administration settings, where you manage connections, users, groups and permissions:
Support
SecureAnyCloud provides 24/7 technical support for this image. Support covers Guacamole deployment and upgrades, and RDP, SSH, VNC and Telnet connection configuration. It also covers LDAP and SAML single sign-on, TOTP two-factor authentication, session recording, performance tuning and database administration.
Contact the SecureAnyCloud support team through the channel listed on your AWS Marketplace subscription.
Deploy on AWS
Launch Apache Guacamole on AWS with 24/7 support from SecureAnyCloud.
View on Marketplace
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com