Browser-based remote desktop gateway compose example.
Educational example only. Review every volume path, port, and credential before you run this. Do not copy production secrets into your wiki or git repo.
_shared/.env for non-secrets, _shared/.secret for credentialsmkdir -p /path/to/docker/stacks/guacamole
cd /path/to/docker/stacks/guacamole
# paste compose.yaml below, then:
docker compose pull
docker compose up -d
---
services:
guacd:
image: guacamole/guacd:latest
container_name: guacd
env_file:
- /path/to/docker/stacks/_shared/.env
- /path/to/docker/stacks/_shared/.secret
volumes:
- /path/to/docker/data/guacamole/drive:/drive:rw
- /path/to/docker/data/guacamole/record:/record:rw
restart: unless-stopped
guacamole:
image: guacamole/guacamole:latest
container_name: guacamole
env_file:
- /path/to/docker/stacks/_shared/.env
- /path/to/docker/stacks/_shared/.secret
depends_on:
- guacd
environment:
# Guacamole connection to guacd
- GUACD_HOSTNAME=guacd
- GUACD_PORT=4822
# PostgreSQL connection (remote)
#- POSTGRESQL_DATABASE=guacamole
#- POSTGRESQL_HOSTNAME=YOUR_HOST.YOUR_DOMAIN
#- POSTGRESQL_PASSWORD=CHANGE_ME
#- POSTGRESQL_USERNAME=webftp
# Remote MySQL configuration (remote)
#- MYSQL_HOSTNAME=${DB_MYSQL_HOST}
- MYSQL_DATABASE=guacamole
#- MYSQL_USERNAME=${DB_USER:?err}
#- MYSQL_PASSWORD=CHANGE_ME
- RECORDING_SEARCH_PATH=/record
# LDAP Authentication
- LDAP_HOSTNAME=YOUR_HOST.YOUR_DOMAIN
- LDAP_PORT=389 # or 636 for LDAPS
- LDAP_ENCRYPTION_METHOD=none # or ssl, starttls
- LDAP_USER_BASE_DN=ou=YOUR_ORG,dc=YOUR_DOMAIN,dc=com
- LDAP_USERNAME_ATTRIBUTE=uid # or sAMAccountName for Active Directory
# LDAP_SEARCH_BIND_DN: cn=searchuser,dc=example,dc=com # Optional, if a dedicated search user is needed
# LDAP_SEARCH_BIND_PASSWORD: your_ldap_search_password # Optional
logging:
driver: json-file
options:
max-file: ${DOCKERLOGGING_MAXFILE:-10} # Max number of log files
max-size: ${DOCKERLOGGING_MAXSIZE:-200k} # Max file size
volumes:
- /path/to/docker/data/guacamole/record:/record:rw
ports:
## enable next line if not using nginx
## - 8080:8080/tcp # Guacamole is on :8080/guacamole, not /.
## enable next line when using nginx
- 30006:8080/tcp
restart: unless-stopped
_shared/.secret.