From 55b1fe013fd9b68bcd41c1ff0b555bde0998bd56 Mon Sep 17 00:00:00 2001 From: thelamer Date: Mon, 1 Nov 2021 11:22:18 -0700 Subject: [PATCH] add subfolder env var docs and set home on backend launch --- README.md | 3 +++ readme-vars.yml | 3 +++ root/etc/services.d/backend/run | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 210c7c2..c8bd744 100644 --- a/README.md +++ b/README.md @@ -89,6 +89,7 @@ services: - PUID=1000 - PGID=1000 - TZ=Europe/London + - SUBFOLDER=/ #optional volumes: - /path/to/data:/data ports: @@ -106,6 +107,7 @@ docker run -d \ -e PUID=1000 \ -e PGID=1000 \ -e TZ=Europe/London \ + -e SUBFOLDER=/ `#optional` \ -p 3000:3000 \ -p 80:80 \ -p 4001:4001 `#optional` \ @@ -126,6 +128,7 @@ Container images are configured using parameters passed at runtime (such as thos | `-e PUID=1000` | for UserID - see below for explanation | | `-e PGID=1000` | for GroupID - see below for explanation | | `-e TZ=Europe/London` | Specify a timezone to use EG Europe/London | +| `-e SUBFOLDER=/` | Specify a subfolder for reverse proxies IE '/FOLDER/' | | `-v /data` | Path to store roms/artwork | ## Environment variables from files (Docker secrets) diff --git a/readme-vars.yml b/readme-vars.yml index 2ab4c44..e86e1f8 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -30,6 +30,9 @@ param_env_vars: opt_param_usage_include_ports: true opt_param_ports: - { external_port: "4001", internal_port: "4001", port_desc: "IPFS peering port, if you want to participate in the P2P network to distribute frontend artwork please forward this to the Internet" } +opt_param_usage_include_env: true +opt_param_env_vars: + - { env_var: "SUBFOLDER", env_value: "/", desc: "Specify a subfolder for reverse proxies IE '/FOLDER/'"} # application setup block app_setup_block_enabled: true diff --git a/root/etc/services.d/backend/run b/root/etc/services.d/backend/run index 43f03e6..3b86749 100644 --- a/root/etc/services.d/backend/run +++ b/root/etc/services.d/backend/run @@ -1,5 +1,5 @@ #!/usr/bin/with-contenv bash cd /emulatorjs || exit -exec \ +HOME=/data exec \ s6-setuidgid abc node index.js