From 5b35084128554b4c0c8d580ba64e1fce347fe4e0 Mon Sep 17 00:00:00 2001 From: Guido Schmutz Date: Fri, 7 Jun 2024 15:10:47 +0200 Subject: [PATCH] add support for docker web console: #891 --- documentation/changes.md | 1 + documentation/configuration.md | 2 ++ documentation/port-mapping.md | 1 + .../services/docker-exec-webconsole.md | 16 ++++++++++ .../generator-config/stack-config.yml | 2 ++ .../templates/docker-compose.yml.j2 | 32 +++++++++++++++++++ .../generator-config/vars/config.yml | 5 +++ 7 files changed, 59 insertions(+) create mode 100644 documentation/services/docker-exec-webconsole.md diff --git a/documentation/changes.md b/documentation/changes.md index facf6578..f76ac31e 100644 --- a/documentation/changes.md +++ b/documentation/changes.md @@ -22,6 +22,7 @@ The Modern Data Platform version 1.18.0 contains the following bug fixes and enh * Weaviate Verba * Unstructured API * gpt-researcher + * Docker Exec Web Console ### Version upgrades diff --git a/documentation/configuration.md b/documentation/configuration.md index 22c3870b..74fc09a1 100644 --- a/documentation/configuration.md +++ b/documentation/configuration.md @@ -1556,6 +1556,8 @@ For each service there might be some other settings, such as controlling the num |------------------------------------------------ |:-------: |------- |------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | [**_Portainer_**](./services/portainer.md)     ![x86-64](./images/x86-64.png) ![arm](./images/arm.png) | | | | | | | `PORTAINER_enable` | `false` | 1.0.0 | Generate Portainer Container UI service | | | +| [**_Docker Exec Web Console_**](./services/docker-exec-webconsole.md)     ![x86-64](./images/x86-64.png) | | | | | | +| `DOCKER_EXEC_WEBCONSOLE_enable` | `false` | 1.0.0 | Generate Docker Exec Web Console service | | | | [**_Rancher_**](./services/rancher.md)     ![x86-64](./images/x86-64.png) ![arm](./images/arm.png) | | | | | | | `RANCHER_enable` | `false` | 1.18.0 | Generate Rancher service | | | | `RANCHER_volume_map_data` | `false` | 1.18.0 | Volume map data folder into the container. | | | diff --git a/documentation/port-mapping.md b/documentation/port-mapping.md index 13c0b9ab..7827d511 100644 --- a/documentation/port-mapping.md +++ b/documentation/port-mapping.md @@ -635,6 +635,7 @@ Container Port(s) | Internal Port(s) | Service (alternatives) | 28372 | 5001 | nlm-ingestor | 28373 | 8000 | verba | 28374 | 8000 | unstructured-api | +28375 | 8888 | docker-exec-webconsole | ## Ports > 28500 diff --git a/documentation/services/docker-exec-webconsole.md b/documentation/services/docker-exec-webconsole.md new file mode 100644 index 00000000..c8df4757 --- /dev/null +++ b/documentation/services/docker-exec-webconsole.md @@ -0,0 +1,16 @@ +# `docker exec` web console + +A web UI to docker exec from the browser + +**[Documentation](https://github.com/bitbull-team/docker-exec-web-console)** | **[GitHub](https://github.com/bitbull-team/docker-exec-web-console)** + +## How to enable? + +``` +platys init --enable-services DOCKER_EXEC_WEBCONSOLE +platys gen +``` + +## How to use it? + +Navigate to . \ No newline at end of file diff --git a/modern-data-platform-stack/generator-config/stack-config.yml b/modern-data-platform-stack/generator-config/stack-config.yml index 4a421745..4a10bf2b 100644 --- a/modern-data-platform-stack/generator-config/stack-config.yml +++ b/modern-data-platform-stack/generator-config/stack-config.yml @@ -763,6 +763,8 @@ vars: # Portainer PORTAINER_version: alpine-sts + # Docker Exec Web Console + DOCKER_EXEC_WEBCONSOLE_version: latest # Rancher RANCHER_version: latest diff --git a/modern-data-platform-stack/generator-config/templates/docker-compose.yml.j2 b/modern-data-platform-stack/generator-config/templates/docker-compose.yml.j2 index afa74561..f7422aad 100755 --- a/modern-data-platform-stack/generator-config/templates/docker-compose.yml.j2 +++ b/modern-data-platform-stack/generator-config/templates/docker-compose.yml.j2 @@ -519,6 +519,7 @@ networks: {% set __ETCD_version = ETCD_version | default('latest') -%} {% set __ETCD_BROWSER_version = ETCD_BROWSER_version | default('latest') -%} {% set __PORTAINER_version = PORTAINER_version | default('latest') -%} +{% set __DOCKER_EXEC_WEBCONSOLE_version = DOCKER_EXEC_WEBCONSOLE_version | default('latest') -%} {% set __RANCHER_version = RANCHER_version | default('latest') -%} {% set __CETUSGUARD_version = CETUSGUARD_version | default('latest') -%} {% set __CADVISOR_version = CADVISOR_version | default('latest') -%} @@ -872,6 +873,7 @@ networks: {% set FIREFOX_enable = false -%} {% set FILE_BROWSER_enable = false -%} {% set ETCD_E3W_enable = false -%} + {% set DOCKER_EXEC_WEBCONSOLE_enable = false -%} {% set CADVISOR_enable = false -%} {% set DOCKER_REGISTRY_enable = false -%} {% set DOCKER_REGISTRY_UI_enable = false -%} @@ -20870,6 +20872,36 @@ services: restart: {{container_restart_policy}} {% endif %} {# PORTAINER_enable #} +{% if DOCKER_EXEC_WEBCONSOLE_enable | default(false) %} + # ================================== Portainer ========================================== # + docker-exec-webconsole: + image: bitbull/docker-exec-web-console:{{__DOCKER_EXEC_WEBCONSOLE_version}} + container_name: docker-exec-webconsole + hostname: docker-exec-webconsole + labels: + com.platys.name: "docker-exec-webconsole" + com.platys.description: "Docker Exec Web Console" + com.platys.webui.title: "Docker Exec Web Console" + com.platys.webui.url: "http://dataplatform:28375" + ports: + - 28375:8888 + {%if use_timezone | default(false) %} + environment: + TZ: {{use_timezone}} + {% endif -%} {# use_timezone #} + volumes: + - ./data-transfer:/data-transfer + - /var/run/docker.sock:/var/run/docker.sock + {%if use_timezone | default(false) %} + - "./etc/timezone:/etc/timezone:ro" + - "./etc/localtime:/etc/localtime:ro" + {% endif -%} {# use_timezone #} + {%if logging_driver is defined and logging_driver and logging_driver in ('fluentd','loki','syslog','splunk') | default(false) %} + <<: *logging + {% endif -%} {# logging_driver is defined ... #} + restart: {{container_restart_policy}} +{% endif %} {# DOCKER_EXEC_WEBCONSOLE_enable #} + {% if RANCHER_enable | default(false) %} # ================================== Rancher ========================================== # rancher: diff --git a/modern-data-platform-stack/generator-config/vars/config.yml b/modern-data-platform-stack/generator-config/vars/config.yml index 94e9ead8..812d386c 100644 --- a/modern-data-platform-stack/generator-config/vars/config.yml +++ b/modern-data-platform-stack/generator-config/vars/config.yml @@ -2456,6 +2456,11 @@ # PORTAINER_enable: false + # + # ===== Docker Exec Web Console ======== + # + DOCKER_EXEC_WEBCONSOLE_enable: false + # # ===== Rancher UI ======== #