diff --git a/templates/apache-guacamole/0/README.md b/templates/apache-guacamole/0/README.md new file mode 100644 index 0000000..5ec7aab --- /dev/null +++ b/templates/apache-guacamole/0/README.md @@ -0,0 +1,21 @@ +# Apache Guacamole + +Apache Guacamole is a clientless remote desktop gateway. It supports standard protocols like VNC, RDP, and SSH. +We call it clientless because no plugins or client software are required. +Thanks to HTML5, once Guacamole is installed on a server, all you need to access your desktops is a web browser. + +This service uses the official Apache [http://guacamole.incubator.apache.org](https://hub.docker.com/r/glyptodon/guacamole/) Guacamole image. It also uses the official MariaDB image as its backend. +Health checks are enabled on all services. +## Prerequisites +You must have the Rancher-NFS storage driver set up. This is required for persistent SQL storage, otherwise all users and connection settings will be reset on every container move. + +## How to use + +Using all default settings will work. The MySQL root password is randomly generated and has "one time password" set. +After starting, the initial database setup will be executed by a runonce container. +The default login will be `guacadmin/guacadmin`. + +This stack exposes Guacamole on port 8080 by default. You can use it as it is, or map a load balancer to it and not expose the port. + +Once all containers are running, Guacamole is available on `http://[container_ip]:8080/`. +If the page is blank, try refreshing the page after 5-10 seconds, since the database container might still be initializing. \ No newline at end of file diff --git a/templates/apache-guacamole/0/docker-compose.yml b/templates/apache-guacamole/0/docker-compose.yml new file mode 100644 index 0000000..0db26a8 --- /dev/null +++ b/templates/apache-guacamole/0/docker-compose.yml @@ -0,0 +1,50 @@ +version: '2' +volumes: + db: + driver: rancher-nfs +services: + guacamole: + image: glyptodon/guacamole + environment: + MYSQL_HOSTNAME: database + MYSQL_DATABASE: ${guacamole_db} + MYSQL_PASSWORD: ${guacamole_password} + MYSQL_USER: ${guacamole_user} + command: + - /bin/bash + - -c + - "cd /usr/local/tomcat/webapps;rm -rf ROOT/; ln -s guacamole.war ROOT.war; /opt/guacamole/bin/start.sh;" + ports: + - ${public_port}:8080 + links: + - guacd:guacd + depends_on: + - database + guacd: + image: glyptodon/guacd + setup-get-db-script: + image: glyptodon/guacamole + volumes: + - /docker-entrypoint-initdb.d + command: + - bash + - -c + - /opt/guacamole/bin/initdb.sh --mysql > /docker-entrypoint-initdb.d/initdb.sql + labels: + io.rancher.container.start_once: 'true' + database: + image: mariadb + environment: + MYSQL_DATABASE: ${guacamole_db} + MYSQL_ONETIME_PASSWORD: 'true' + MYSQL_PASSWORD: ${guacamole_password} + MYSQL_RANDOM_ROOT_PASSWORD: 'true' + MYSQL_USER: ${guacamole_user} + labels: + io.rancher.sidekicks: setup-get-db-script + depends_on: + - setup-get-db-script + volumes_from: + - setup-get-db-script + volumes: + - db:/var/lib/mysql \ No newline at end of file diff --git a/templates/apache-guacamole/0/rancher-compose.yml b/templates/apache-guacamole/0/rancher-compose.yml new file mode 100644 index 0000000..0f757ea --- /dev/null +++ b/templates/apache-guacamole/0/rancher-compose.yml @@ -0,0 +1,68 @@ +version: '2' +services: + guacamole: + scale: 1 + health_check: + healthy_threshold: 2 + response_timeout: 2000 + port: 8080 + unhealthy_threshold: 3 + initializing_timeout: 60000 + interval: 2000 + strategy: recreate + request_line: GET "/guacamole" "HTTP/1.0" + reinitializing_timeout: 60000 + guacd: + scale: 1 + health_check: + healthy_threshold: 2 + response_timeout: 2000 + port: 4822 + unhealthy_threshold: 3 + initializing_timeout: 60000 + interval: 2000 + strategy: recreate + reinitializing_timeout: 60000 + setup-get-db-script: + scale: 1 + mysql: + scale: 1 + health_check: + healthy_threshold: 2 + response_timeout: 2000 + port: 3306 + unhealthy_threshold: 3 + initializing_timeout: 60000 + interval: 2000 + strategy: recreate + reinitializing_timeout: 60000 +.catalog: + name: "apache-guacamole" + version: "0.1-rancher1" + description: " Apache Guacamole is a clientless remote desktop gateway. It supports standard protocols like VNC, RDP, and SSH." + minimum_rancher_version: v0.46.0 + questions: + - variable: "guacamole_db" + label: "MySQL Database Name" + description: "Your MYSQL guacamole database name" + default: "guacamole_db" + required: true + type: "string" + - variable: "guacamole_user" + label: "MySQL Database User" + description: "Your MYSQL guacamole user name" + required: true + default: "guacamole_user" + type: "string" + - variable: "guacamole_password" + label: "MySQL Database Password" + description: "Your MYSQL guacamole user password. Defaults to \"guacamole_password\"" + required: true + default: "guacamole_password" + type: "password" + - variable: "public_port" + label: "Public Port" + description: "The public port that Guacamole listens on, defaults to 8080" + required: true + default: 8080 + type: "int" diff --git a/templates/apache-guacamole/catalogIcon-apache-guacamole.png b/templates/apache-guacamole/catalogIcon-apache-guacamole.png new file mode 100644 index 0000000..5ff25d1 Binary files /dev/null and b/templates/apache-guacamole/catalogIcon-apache-guacamole.png differ diff --git a/templates/apache-guacamole/config.yml b/templates/apache-guacamole/config.yml new file mode 100644 index 0000000..4696941 --- /dev/null +++ b/templates/apache-guacamole/config.yml @@ -0,0 +1,8 @@ +name: Apache Guacamole +description: | + Apache Guacamole is a clientless remote desktop gateway. It supports standard protocols like VNC, RDP, and SSH. +version: 0.1-rancher1 +category: Applications +license: +maintainer: "Kevin Xu " +projectURL: https://github.com/glyptodon/guacamole-docker \ No newline at end of file