From a35216fdfb08262d6afa0303e5f6331a17cc0f05 Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 19:35:54 +0100 Subject: [PATCH 01/27] Add Docker Compose Override File for Multi PHP versions --- .../docker-compose.override.yml-php-multi.yml | 165 ++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 compose/docker-compose.override.yml-php-multi.yml diff --git a/compose/docker-compose.override.yml-php-multi.yml b/compose/docker-compose.override.yml-php-multi.yml new file mode 100644 index 000000000..12bcc31a0 --- /dev/null +++ b/compose/docker-compose.override.yml-php-multi.yml @@ -0,0 +1,165 @@ +# vim: set ft=yaml: +--- +version: '2.3' + +# ------------------------------------------------------------ +# Yaml Default +# ------------------------------------------------------------ + +x-app: &default-php + env_file: + - ./.env + + environment: + ## + ## Debug/Logging + ## + - DEBUG_ENTRYPOINT=${DEBUG_ENTRYPOINT:-2} + - DOCKER_LOGS=1 + + ## + ## Enable/Disable PHP Modules + ## + - ENABLE_MODULES=${PHP_MODULES_ENABLE} + - DISABLE_MODULES=${PHP_MODULES_DISABLE} + + ## + ## Mail-catching + ## + - ENABLE_MAIL=${PHP_MAIL_CATCH_ALL:-2} + dns: + - 172.16.238.100 + + volumes: + # ---- Format: ---- + # HOST-DIRECTORY : DOCKER-DIRECTORY + + # Mount custom mass virtual hosting + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + + # Mount Mail directory + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} + + # Mount devilbox user-defined *.ini files in order + # to overwrite the default PHP.ini configuration + - ${DEVILBOX_PATH}/cfg/php-ini-${PHP_SERVER}:/etc/php-custom.d:ro${MOUNT_OPTIONS} + + # Mount devilbox user-defined PHP-FPM *.conf files in order + # to overwrite the default PHP-FPM configuration + - ${DEVILBOX_PATH}/cfg/php-fpm-${PHP_SERVER}:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + + # Mount devilbox user-defined *.so files in order + # to load custom PHP modules + - ${DEVILBOX_PATH}/mod/php-fpm-${PHP_SERVER}:/usr/lib64/php/custom-modules:ro${MOUNT_OPTIONS} + + # Mount devilbox user-defined PHP-FPM startup *.sh scripts + - ${DEVILBOX_PATH}/cfg/php-startup-${PHP_SERVER}:/startup.1.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + + # Mount devilbox user-defined bash config + - ${DEVILBOX_PATH}/bash:/etc/bashrc-devilbox.d:rw${MOUNT_OPTIONS} + + # Mount devilbox user-defined supervisord config + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + + # Certificate Authority public key + - ${DEVILBOX_PATH}/ca:/ca:rw${MOUNT_OPTIONS} + + # Users SSH directory (read-only) + - ${HOST_PATH_SSH_DIR}:/home/devilbox/.ssh:ro${MOUNT_OPTIONS} + + depends_on: + - bind + + +# ------------------------------------------------------------ +# PHP Services +# ------------------------------------------------------------ +services: + php54: + <<: *default-php + image: devilbox/php-fpm:5.4-prod-0.147 + hostname: php54 + networks: + app_net: + ipv4_address: 172.16.238.201 + + php55: + <<: *default-php + image: devilbox/php-fpm:5.5-prod-0.147 + hostname: php55 + networks: + app_net: + ipv4_address: 172.16.238.202 + + php56: + <<: *default-php + image: devilbox/php-fpm:5.6-prod-0.147 + hostname: php56 + networks: + app_net: + ipv4_address: 172.16.238.203 + + php70: + <<: *default-php + image: devilbox/php-fpm:7.0-prod-0.147 + hostname: php70 + networks: + app_net: + ipv4_address: 172.16.238.204 + + php71: + <<: *default-php + image: devilbox/php-fpm:7.1-prod-0.147 + hostname: php71 + networks: + app_net: + ipv4_address: 172.16.238.205 + + php72: + <<: *default-php + image: devilbox/php-fpm:7.2-prod-0.147 + hostname: php72 + networks: + app_net: + ipv4_address: 172.16.238.206 + + php73: + <<: *default-php + image: devilbox/php-fpm:7.3-prod-0.147 + hostname: php73 + networks: + app_net: + ipv4_address: 172.16.238.207 + + php74: + <<: *default-php + image: devilbox/php-fpm:7.4-prod-0.147 + hostname: php74 + networks: + app_net: + ipv4_address: 172.16.238.208 + + php80: + <<: *default-php + image: devilbox/php-fpm:8.0-prod-0.147 + hostname: php80 + networks: + app_net: + ipv4_address: 172.16.238.209 + + php81: + <<: *default-php + image: devilbox/php-fpm:8.1-prod-0.147 + hostname: php81 + networks: + app_net: + ipv4_address: 172.16.238.210 + + php82: + <<: *default-php + image: devilbox/php-fpm:8.2-prod-0.147 + hostname: php82 + networks: + app_net: + ipv4_address: 172.16.238.211 From f2c0372618106934dd4b242c5d5b685dcc63de89 Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 19:36:10 +0100 Subject: [PATCH 02/27] Update DNS server to latest version --- docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index 9deedd011..b2a194141 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -34,7 +34,7 @@ services: # Bind (DNS Server) # ------------------------------------------------------------ bind: - image: cytopia/bind:alpine-0.34 + image: cytopia/bind:alpine-0.35 hostname: bind restart: always ports: From d354d8416562024819e189c939f772fbae410daa Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 19:37:50 +0100 Subject: [PATCH 03/27] Update intranet and docker-compose --- .devilbox/www/config.php | 4 +- .devilbox/www/htdocs/cnc.php | 129 +++++++++++++++++++++++++++++ .devilbox/www/htdocs/mail.php | 2 +- .devilbox/www/htdocs/vhosts.php | 2 +- .devilbox/www/include/lib/Html.php | 4 + docker-compose.yml | 52 +++++++----- env-example | 31 ++++--- 7 files changed, 191 insertions(+), 33 deletions(-) create mode 100644 .devilbox/www/htdocs/cnc.php diff --git a/.devilbox/www/config.php b/.devilbox/www/config.php index 38f67ebbf..5e0768350 100644 --- a/.devilbox/www/config.php +++ b/.devilbox/www/config.php @@ -13,8 +13,8 @@ putenv('RES_OPTIONS=retrans:1 retry:1 timeout:1 attempts:1'); -$DEVILBOX_VERSION = 'v2.4.0'; -$DEVILBOX_DATE = '2022-12-18'; +$DEVILBOX_VERSION = 'v3.0.0-beta-0.1'; +$DEVILBOX_DATE = '2022-12-23'; $DEVILBOX_API_PAGE = 'devilbox-api/status.json'; // diff --git a/.devilbox/www/htdocs/cnc.php b/.devilbox/www/htdocs/cnc.php new file mode 100644 index 000000000..1073721c8 --- /dev/null +++ b/.devilbox/www/htdocs/cnc.php @@ -0,0 +1,129 @@ + +authPage(); ?> +exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf restart watcherd'); + sleep(1); + loadClass('Helper')->redirect('/cnc.php'); +} +?> + + + + getHead(true); ?> + + + + getNavbar(); ?> + +
+

Command & Control

+
+
+ +
+
+ + exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status watcherd'); + $status_h = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status httpd'); + + $words = preg_split("/\s+/", $status_w); + $data_w = array( + 'name' => $words[0], + 'state' => $words[1], + 'pid' => preg_replace('/,$/', '', $words[3]), + 'uptime' => $words[5], + ); + $words = preg_split("/\s+/", $status_h); + $data_h = array( + 'name' => $words[0], + 'state' => $words[1], + 'pid' => preg_replace('/,$/', '', $words[3]), + 'uptime' => $words[5], + ); + ?> +

Daemon overview


+

If you made a change to any vhost settings, you can trigger a manual reload here.

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
DaemonStatusPidUptimeAction
+
+
+ +

watcherd stderr

+
+ exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd stderr'); + echo '
' . $output . '
'; + ?> +

watcherd stdout

+
+ exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd'); + echo '
' . $output . '
'; + ?> + +
+
+ +
+ + getFooter(); ?> + + + diff --git a/.devilbox/www/htdocs/mail.php b/.devilbox/www/htdocs/mail.php index 21dc6990c..50e73b320 100644 --- a/.devilbox/www/htdocs/mail.php +++ b/.devilbox/www/htdocs/mail.php @@ -250,7 +250,7 @@ $.get('?get-body=' + id, function(response){ response = JSON.parse(response); row.find('.raw-email-body').html(response.raw); - + const body = response.body; if(body === null){ row.find('.alert').show(); diff --git a/.devilbox/www/htdocs/vhosts.php b/.devilbox/www/htdocs/vhosts.php index 89881992e..9f643c5cd 100644 --- a/.devilbox/www/htdocs/vhosts.php +++ b/.devilbox/www/htdocs/vhosts.php @@ -31,7 +31,7 @@ 'Virtual Hosts', 'path' => '/vhosts.php' ), + array( + 'name' => 'C&C', + 'path' => '/cnc.php' + ), array( 'name' => 'Emails', 'path' => '/mail.php' diff --git a/docker-compose.yml b/docker-compose.yml index b2a194141..63e31b44f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -46,7 +46,7 @@ services: ## ## Debug? ## - - DEBUG_ENTRYPOINT=${DEBUG_COMPOSE_ENTRYPOINT} + - DEBUG_ENTRYPOINT=${DEBUG_ENTRYPOINT:-2} ## ## Memory consumption @@ -112,11 +112,17 @@ services: - ./.env environment: + ## + ## Supervisord Management (to connect to HTTPD supvervisord) + ## + - SVCTL_LISTEN_PORT=9001 + - SVCTL_USER=${DEVILBOX_HTTPD_MGMT_USER:-supervisor} + - SVCTL_PASS=${DEVILBOX_HTTPD_MGMT_PASS:-mypassword} + ## ## Debug/Logging ## - - DEBUG_ENTRYPOINT=${DEBUG_COMPOSE_ENTRYPOINT} - - DEBUG_COMPOSE_ENTRYPOINT + - DEBUG_ENTRYPOINT=${DEBUG_ENTRYPOINT:-2} - DOCKER_LOGS ## @@ -225,16 +231,26 @@ services: # Web Server # ------------------------------------------------------------ httpd: - image: devilbox/${HTTPD_SERVER}:${HTTPD_FLAVOUR:-alpine}-0.48 + image: devilbox/${HTTPD_SERVER}:${HTTPD_FLAVOUR:-alpine}-release-0.49b hostname: httpd environment: + ## + ## Supervisord Management + ## + - SVCTL_ENABLE=1 + - SVCTL_LISTEN_ADDR=0.0.0.0 + - SVCTL_LISTEN_PORT=9001 + - SVCTL_REMOTE_LOGS_ENABLE=1 + - SVCTL_USER=${DEVILBOX_HTTPD_MGMT_USER:-supervisor} + - SVCTL_PASS=${DEVILBOX_HTTPD_MGMT_PASS:-mypassword} + ## ## Debug/Logging ## - - DEBUG_ENTRYPOINT=${DEBUG_COMPOSE_ENTRYPOINT} - - DEBUG_RUNTIME=${DEBUG_COMPOSE_ENTRYPOINT} + - DEBUG_ENTRYPOINT=${DEBUG_ENTRYPOINT:-2} + - DEBUG_RUNTIME=1 - DOCKER_LOGS ## @@ -268,25 +284,23 @@ services: - MAIN_VHOST_SSL_TYPE=${HTTPD_VHOST_SSL_TYPE:-both} - MAIN_VHOST_SSL_GEN=1 - MAIN_VHOST_SSL_CN=${DEVILBOX_UI_SSL_CN:-localhost} + - MAIN_VHOST_BACKEND=conf:phpfpm:tcp:172.16.238.10:9000 + - MAIN_VHOST_BACKEND_TIMEOUT=${HTTPD_BACKEND_TIMEOUT:-180} + - MAIN_VHOST_ALIASES_ALLOW=/devilbox-api/:/var/www/default/api, /vhost.d/:/etc/httpd ## ## Enable Mass Vhosts ## - MASS_VHOST_ENABLE=1 - - MASS_VHOST_TLD=.${TLD_SUFFIX} - - MASS_VHOST_DOCROOT=${HTTPD_DOCROOT_DIR} - - MASS_VHOST_TPL=${HTTPD_TEMPLATE_DIR} + - MASS_VHOST_TLD_SUFFIX=.${TLD_SUFFIX} + - MASS_VHOST_DOCROOT_DIR=${HTTPD_DOCROOT_DIR} + - MASS_VHOST_TEMPLATE_DIR=${HTTPD_TEMPLATE_DIR} - MASS_VHOST_SSL_TYPE=${HTTPD_VHOST_SSL_TYPE:-both} - MASS_VHOST_SSL_GEN=1 - - ## - ## PHP-FPM Remote Server - ## - - COMPAT=${PHP_SERVER} - - PHP_FPM_ENABLE=1 - - PHP_FPM_SERVER_ADDR=172.16.238.10 - - PHP_FPM_SERVER_PORT=9000 - - PHP_FPM_TIMEOUT=${HTTPD_TIMEOUT_TO_PHP_FPM:-180} + - MASS_VHOST_BACKEND=conf:phpfpm:tcp:172.16.238.10:9000 + - MASS_VHOST_BACKEND_REWRITE=file:backend.cfg + - MASS_VHOST_BACKEND_TIMEOUT=${HTTPD_BACKEND_TIMEOUT:-180} + - MASS_VHOST_ALIASES_ALLOW=/devilbox-api/:/var/www/default/api:http(s)?://(.*)$$ ports: # ---- Format: ---- @@ -315,7 +329,7 @@ services: - ${DEVILBOX_PATH}/cfg/vhost-gen:/etc/vhost-gen.d:rw${MOUNT_OPTIONS} # Mount logs - - ${DEVILBOX_PATH}/log/${HTTPD_SERVER}:/var/log/${HTTPD_SERVER}:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/log/${HTTPD_SERVER}:/var/log/httpd:rw${MOUNT_OPTIONS} # Certificate Authority public key - ${DEVILBOX_PATH}/ca:/ca:rw${MOUNT_OPTIONS} diff --git a/env-example b/env-example index 5d4f18f60..d200159b4 100644 --- a/env-example +++ b/env-example @@ -28,10 +28,12 @@ ### Show all executed commands in each ### docker image during docker-compose up? ### -### 0: Quiet -### 1: Verbose -### 2: More verbose -DEBUG_COMPOSE_ENTRYPOINT=2 +### 0: Errors +### 1: Errors, Warnings +### 2: Errors, Warnings, Infos (Recommended) +### 3: Errors, Warnings, Infos, Debug +### 4: Errors, Warnings, Infos, Debug, Trace +DEBUG_ENTRYPOINT=2 ### @@ -236,6 +238,12 @@ DEVILBOX_VENDOR_PHPMYADMIN_AUTOLOGIN=1 ### DEVILBOX_VENDOR_PHPPGADMIN_AUTOLOGIN=1 +### +### HTTPD Supvervisord management +### +DEVILBOX_HTTPD_MGMT_USER=supervisord +DEVILBOX_HTTPD_MGMT_PASS=mypassword + ################################################################################ @@ -515,7 +523,7 @@ PHP_MODULES_ENABLE= ### ### PHP_MODULES_DISABLE=xdebug,imagick,swoole ### -PHP_MODULES_DISABLE=oci8,PDO_OCI,pdo_sqlsrv,sqlsrv,rdkafka,swoole +PHP_MODULES_DISABLE=oci8,PDO_OCI,pdo_sqlsrv,sqlsrv,rdkafka,swoole,psr,phalcon ### @@ -609,13 +617,16 @@ HTTPD_TEMPLATE_DIR=.devilbox ### -### Webserver timeout (in seconds) to upstream PHP-FPM server +### Remote (Upstream) Backend Timeout +### +### This setting specifies the Timeout for a remote Backend server, +### such as PHP-FPM or a Reverse Proxy. ### -### This value should be greater than PHP's max_execution_time, -### otherwise the php script could still run and the webserver will -### simply drop the connection before getting an answer by PHP. +### As for PHP, keep in mind that this value should be greater than +### PHP's max_execution_time,otherwise the php script could still +### run and the webserver will simply drop the connection before getting an answer by PHP. ### -HTTPD_TIMEOUT_TO_PHP_FPM=180 +HTTPD_BACKEND_TIMEOUT=180 ### From ee5988507ee3cede72d275a95961a16b8c1db9a2 Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 19:41:42 +0100 Subject: [PATCH 04/27] Update CHANGELOG --- .devilbox/www/config.php | 2 +- CHANGELOG.md | 82 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 83 insertions(+), 1 deletion(-) diff --git a/.devilbox/www/config.php b/.devilbox/www/config.php index 5e0768350..2c4cc582c 100644 --- a/.devilbox/www/config.php +++ b/.devilbox/www/config.php @@ -14,7 +14,7 @@ $DEVILBOX_VERSION = 'v3.0.0-beta-0.1'; -$DEVILBOX_DATE = '2022-12-23'; +$DEVILBOX_DATE = '2022-12-24'; $DEVILBOX_API_PAGE = 'devilbox-api/status.json'; // diff --git a/CHANGELOG.md b/CHANGELOG.md index 4c4e56b37..a4874fa72 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,88 @@ Make sure to have a look at [UPDATING.md](https://github.com/cytopia/devilbox/bl ## Unreleased +## Release v3.0.0-beta-0.1 (2022-12-24) 🎅🎄🎁 + +This is a beta release, using a completely rewritten set of HTTPD server, which allow easy reverse Proxy integration and different PHP versions per project: + +* https://github.com/devilbox/docker-nginx-stable/pull/55 +* https://github.com/devilbox/docker-nginx-mainline/pull/57 +* https://github.com/devilbox/docker-apache-2.2/pull/53 +* https://github.com/devilbox/docker-apache-2.4/pull/54 + +Once it has been tested by the community, and potential errors have been addressed, a new major version will be released. + +**IMPORTANT:** This release required you to copy `env-example` over onto `.env` due to some changes in variables. + +### TL;DR + +1. **Multiple PHP Versions**
+ Here is an example to run one project with a specific PHP version
+ ```bash + # Enable all PHP versions + cp compose/docker-compose.override.yml-php-multi.yml docker-compose.override.yml + # Start default set and php80 + docker-compose up php httpd bind php80 + ``` + file: `/shared/httpd//.devilbox/backend.cfg` + ``` + conf:phpfpm:tcp:php80:9000 + ``` +2. **Automated Reverse Proxy setup**
+ Here is an example to proxy one project to a backend service (e.g. NodeJS or Python application, which runs in the PHP container on port 3000)
+ file: `/shared/httpd//.devilbox/backend.cfg` + ``` + conf:rproxy:http:127.0.0.1:3000 + ``` +#### PHP hostnames and IP addresses + +| PHP Version | Hostname | IP address | +|-------------|----------|----------------| +| 5.4 | php54 | 172.16.238.201 | +| 5.5 | php54 | 172.16.238.202 | +| 5.6 | php54 | 172.16.238.203 | +| 7.0 | php70 | 172.16.238.204 | +| 7.1 | php71 | 172.16.238.205 | +| 7.2 | php72 | 172.16.238.206 | +| 7.3 | php73 | 172.16.238.207 | +| 7.4 | php74 | 172.16.238.208 | +| 8.0 | php80 | 172.16.238.209 | +| 8.1 | php81 | 172.16.238.210 | +| 8.2 | php82 | 172.16.238.211 | + +### Important + +Currently the Intranet Command and Control Center is not yet self sufficient as it requires a supervisord configuration file. + +In the root of the Devilbox repository, add `supervisorctl.conf` into `supervisor/` directory. **Important:** It must have this name. +```ini +[supervisorctl] +serverurl=http://httpd:9001 +username=supervisord +password=mypassword +``` + +### Fixed +- Fixed Protocol substitution bug in Reverse Proxy generation for Apache 2.2 and Apache 2.4 [vhost-gen #49](https://github.com/devilbox/vhost-gen/pull/49) [vhost-gen #50](https://github.com/devilbox/vhost-gen/pull/50) +- Fixed missing module `mod_proxy_html` in Apache 2.4 as per requirement from `vhost-gen` for Reverse Proxy setup +- Fixed encoding issue with Apache 2.4 Reverse Proxy by enabling `mod_xml2enc` module (Required by `mod_proxy_html`) +- Allow to run different PHP versions per project. fixes [#146](https://github.com/cytopia/devilbox/issues/146) + +### Added +- New HTTPD server capable of auto reverse proxy creation (and different PHP versions per project) +- Intranet: Added Command & Control center to view watcherd logs and retrigger config in case of vhost changes +- Environment variable `DEVILBOX_HTTPD_MGMT_PASS` +- Environment variable `DEVILBOX_HTTPD_MGMT_USER` +- New Docker Compose Override file `docker-compose.override.yml-php-multi.yml` (allows to run multiple PHP versions). +- Update Bind to latest version + +### Changed +- Disabled `psr` extension by default [php-psr #78](https://github.com/jbboehr/php-psr/issues/78#issuecomment-722290110) +- Disabled `phalcon` extension by default +- Environment variable `DEBUG_COMPOSE_ENTRYPOINT` renamed to `DEBUG_ENTRYPOINT` +- Environment variable `HTTPD_TIMEOUT_TO_PHP_FPM` renamed to `HTTPD_BACKEND_TIMEOUT` + + ## Release v2.4.0 (2022-12-18) This release might be a bit bumpy due to a massive amount of changes in upstream projects. If you encounter issues, please do raise tickets. From 2b4bf59a40daa4657dd37465122144103bbea28d Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 19:59:14 +0100 Subject: [PATCH 05/27] Add missing mariadb config directories --- cfg/mariadb-10.10/.keepme | 0 cfg/mariadb-10.10/devilbox-custom.cnf-example | 5 +++++ cfg/mariadb-10.8/.keepme | 0 cfg/mariadb-10.8/devilbox-custom.cnf-example | 5 +++++ cfg/mariadb-10.9/.keepme | 0 cfg/mariadb-10.9/devilbox-custom.cnf-example | 5 +++++ 6 files changed, 15 insertions(+) create mode 100644 cfg/mariadb-10.10/.keepme create mode 100644 cfg/mariadb-10.10/devilbox-custom.cnf-example create mode 100644 cfg/mariadb-10.8/.keepme create mode 100644 cfg/mariadb-10.8/devilbox-custom.cnf-example create mode 100644 cfg/mariadb-10.9/.keepme create mode 100644 cfg/mariadb-10.9/devilbox-custom.cnf-example diff --git a/cfg/mariadb-10.10/.keepme b/cfg/mariadb-10.10/.keepme new file mode 100644 index 000000000..e69de29bb diff --git a/cfg/mariadb-10.10/devilbox-custom.cnf-example b/cfg/mariadb-10.10/devilbox-custom.cnf-example new file mode 100644 index 000000000..6d2549fa4 --- /dev/null +++ b/cfg/mariadb-10.10/devilbox-custom.cnf-example @@ -0,0 +1,5 @@ +[mysqld] +;key_buffer_size=16M + +[mysqldump] +;quick diff --git a/cfg/mariadb-10.8/.keepme b/cfg/mariadb-10.8/.keepme new file mode 100644 index 000000000..e69de29bb diff --git a/cfg/mariadb-10.8/devilbox-custom.cnf-example b/cfg/mariadb-10.8/devilbox-custom.cnf-example new file mode 100644 index 000000000..6d2549fa4 --- /dev/null +++ b/cfg/mariadb-10.8/devilbox-custom.cnf-example @@ -0,0 +1,5 @@ +[mysqld] +;key_buffer_size=16M + +[mysqldump] +;quick diff --git a/cfg/mariadb-10.9/.keepme b/cfg/mariadb-10.9/.keepme new file mode 100644 index 000000000..e69de29bb diff --git a/cfg/mariadb-10.9/devilbox-custom.cnf-example b/cfg/mariadb-10.9/devilbox-custom.cnf-example new file mode 100644 index 000000000..6d2549fa4 --- /dev/null +++ b/cfg/mariadb-10.9/devilbox-custom.cnf-example @@ -0,0 +1,5 @@ +[mysqld] +;key_buffer_size=16M + +[mysqldump] +;quick From e3b7c2d4db919c2a6f256079f76234cce6cc4326 Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 20:01:44 +0100 Subject: [PATCH 06/27] Adjust check-config.sh --- check-config.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/check-config.sh b/check-config.sh index d94939b4d..c2d869ffe 100755 --- a/check-config.sh +++ b/check-config.sh @@ -219,13 +219,13 @@ print_head_1 "Checking .env file values" WRONG_ENV_FILES_VALUES=0 -DEBUG_COMPOSE_ENTRYPOINT="$( get_env_value "DEBUG_COMPOSE_ENTRYPOINT" )" -if [ "${DEBUG_COMPOSE_ENTRYPOINT}" != "0" ] && [ "${DEBUG_COMPOSE_ENTRYPOINT}" != "1" ] && [ "${DEBUG_COMPOSE_ENTRYPOINT}" != "2" ]; then - log_err "Variable 'DEBUG_COMPOSE_ENTRYPOINT' should be 0, 1 or 2. Has: ${DEBUG_COMPOSE_ENTRYPOINT}" +DEBUG_ENTRYPOINT="$( get_env_value "DEBUG_ENTRYPOINT" )" +if [ "${DEBUG_ENTRYPOINT}" != "0" ] && [ "${DEBUG_ENTRYPOINT}" != "1" ] && [ "${DEBUG_ENTRYPOINT}" != "2" ] && [ "${DEBUG_ENTRYPOINT}" != "3" ] && [ "${DEBUG_ENTRYPOINT}" != "3" ]; then + log_err "Variable 'DEBUG_ENTRYPOINT' should be 0, 1 or 2. Has: ${DEBUG_ENTRYPOINT}" RET_CODE=$(( RET_CODE + 1)) WRONG_ENV_FILES_VALUES=1 else - log_debug "Variable 'DEBUG_COMPOSE_ENTRYPOINT' has correct value: ${DEBUG_COMPOSE_ENTRYPOINT}" + log_debug "Variable 'DEBUG_ENTRYPOINT' has correct value: ${DEBUG_ENTRYPOINT}" fi DOCKER_LOGS="$( get_env_value "DOCKER_LOGS" )" From 6fa03e6961be1343a933dafca3e35b27b8a9766e Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 21:07:34 +0100 Subject: [PATCH 07/27] Fix env var names in docs --- .github/workflows/zzz-reuse-tests.yml | 2 +- .tests/Makefile | 2 +- .../overwrite-existing-docker-image.rst | 2 +- docs/configuration-files/env-file.rst | 24 +++++++++---------- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/zzz-reuse-tests.yml b/.github/workflows/zzz-reuse-tests.yml index da7441ca2..8e6c783ff 100644 --- a/.github/workflows/zzz-reuse-tests.yml +++ b/.github/workflows/zzz-reuse-tests.yml @@ -76,7 +76,7 @@ jobs: cd "${GITHUB_WORKSPACE}/.tests/" # Test full customization - make configure KEY=DEBUG_COMPOSE_ENTRYPOINT VAL="$(( RANDOM % 3 ))" + make configure KEY=DEBUG_ENTRYPOINT VAL="$(( RANDOM % 3 ))" make configure KEY=DOCKER_LOGS VAL="$(( RANDOM % 1 ))" make configure KEY=TLD_SUFFIX VAL=loc2 make configure KEY=TIMEZONE VAL='Europe/Berlin' diff --git a/.tests/Makefile b/.tests/Makefile index c6869e626..16d8e66e5 100644 --- a/.tests/Makefile +++ b/.tests/Makefile @@ -51,7 +51,7 @@ pull: ../.env ### start: ../.env @$(MAKE) --no-print-directory configure KEY=HOST_PATH_HTTPD_DATADIR VAL=.tests/www - @$(MAKE) --no-print-directory configure KEY=DEBUG_COMPOSE_ENTRYPOINT VAL=2 + @$(MAKE) --no-print-directory configure KEY=DEBUG_ENTRYPOINT VAL=3 @$(MAKE) --no-print-directory configure KEY=NEW_UID VAL=$$(id -u) @$(MAKE) --no-print-directory configure KEY=NEW_GID VAL=$$(id -g) @$(PWD)/scripts/compose-start.sh diff --git a/docs/advanced/overwrite-existing-docker-image.rst b/docs/advanced/overwrite-existing-docker-image.rst index 2d6af888f..eabace3a0 100644 --- a/docs/advanced/overwrite-existing-docker-image.rst +++ b/docs/advanced/overwrite-existing-docker-image.rst @@ -67,7 +67,7 @@ First you simply copy the while definition of the bind service from ``docker-com ## ## Debug? ## - - DEBUG_ENTRYPOINT=${DEBUG_COMPOSE_ENTRYPOINT} + - DEBUG_ENTRYPOINT=${DEBUG_ENTRYPOINT} - DOCKER_LOGS=1 ## diff --git a/docs/configuration-files/env-file.rst b/docs/configuration-files/env-file.rst index 30b2f70cb..fcd339653 100644 --- a/docs/configuration-files/env-file.rst +++ b/docs/configuration-files/env-file.rst @@ -32,18 +32,18 @@ to ``.env`` to initially create it with sane defaults. Core settings ============= -DEBUG_COMPOSE_ENTRYPOINT ------------------------- +DEBUG_ENTRYPOINT +---------------- This variable controls the docker-compose log verbosity during service startup. When set to ``1`` verbose output as well as executed commands are shown. When set to ``0`` only warnings and errors are shown. -+------------------------------+----------------+---------------+ -| Name | Allowed values | Default value | -+==============================+================+===============+ -| ``DEBUG_COMPOSE_ENTRYPOINT`` | ``0`` or ``1`` | ``1`` | -+------------------------------+----------------+---------------+ ++------------------------------+-----------------------------------+---------------+ +| Name | Allowed values | Default value | ++==============================+===================================+===============+ +| ``DEBUG_ENTRYPOINT`` | ``0``, ``1``, ``2``, ``3``, ``4`` | ``2`` | ++------------------------------+-----------------------------------+---------------+ .. _env_docker_logs: @@ -1505,8 +1505,8 @@ changing the server name or adding locations to other assets. .. _env_httpd_timeout_to_php_fpm: -HTTPD_TIMEOUT_TO_PHP_FPM -^^^^^^^^^^^^^^^^^^^^^^^^ +HTTPD_BACKEND_TIMEOUT +^^^^^^^^^^^^^^^^^^^^^ This variable specifies after how many seconds the webserver should quit an unanswered connection to PHP-FPM. @@ -1515,17 +1515,17 @@ Ensure that this value is higher than PHP's ``max_execution_time``, otherwise th could still run and the webserver will simply drop the connection before getting an answer by PHP. -If ``HTTPD_TIMEOUT_TO_PHP_FPM`` is smaller then ``max_execution_time`` and a script runs longer +If ``HTTPD_BACKEND_TIMEOUT`` is smaller then ``max_execution_time`` and a script runs longer than ``max_execution_time``, you will get a: ``504 Gateway timeout`` in the browser. -If ``HTTPD_TIMEOUT_TO_PHP_FPM`` is greater then ``max_execution_time`` and a script runs longer +If ``HTTPD_BACKEND_TIMEOUT`` is greater then ``max_execution_time`` and a script runs longer than ``max_execution_time``, you will get a proper PHP error message in the browser. +------------------------------+-------------------+------------------+ | Name | Allowed values | Default value | +==============================+===================+==================+ -| ``HTTPD_TIMEOUT_TO_PHP_FPM`` | positive integer | ``180`` | +| ``HTTPD_BACKEND_TIMEOUT`` | positive integer | ``180`` | +------------------------------+-------------------+------------------+ HTTPD_NGINX_WORKER_PROCESSES From 6b80453b92197c52200f28ac1bb7e7c2d6d303bb Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 21:42:45 +0100 Subject: [PATCH 08/27] Docs announce --- docs/_includes/snippets/__ANNOUNCEMENTS__.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/_includes/snippets/__ANNOUNCEMENTS__.rst b/docs/_includes/snippets/__ANNOUNCEMENTS__.rst index d5282294b..348b7e8aa 100644 --- a/docs/_includes/snippets/__ANNOUNCEMENTS__.rst +++ b/docs/_includes/snippets/__ANNOUNCEMENTS__.rst @@ -1,11 +1,11 @@ -.. |ext_lnk_php_community_github_announce| raw:: html +.. |ext_lnk_devilbox_pr_announce| raw:: html - - PHP-FPM Community + + Release v3.0.0-beta-0.1 .. attention:: - You can now create your own **custom flavour** of PHP-FPM Community images and easily add them to the Devilbox: |ext_lnk_php_community_github_announce| + You can now run different PHP versions per project: |ext_lnk_devilbox_pr_announce| From e51f34c1ae7620a2208e476905578e8a0229d56e Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 22:28:43 +0100 Subject: [PATCH 09/27] Fix wrong link in docs --- docs/intermediate/enable-disable-php-modules.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/intermediate/enable-disable-php-modules.rst b/docs/intermediate/enable-disable-php-modules.rst index aa875b921..044563a97 100644 --- a/docs/intermediate/enable-disable-php-modules.rst +++ b/docs/intermediate/enable-disable-php-modules.rst @@ -11,7 +11,7 @@ Enable/disable PHP modules .. contents:: :local: .. seealso:: - https://github.com/devilbox/docker-php-fpm#user-content-php-modules + https://github.com/devilbox/docker-php-fpm/blob/master/doc/php-modules.md Follow the link to see all available PHP modules for each different PHP-FPM server version. From 794bf0c27c69a72152f6ced3174ef5a4b84c0c4f Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 22:52:56 +0100 Subject: [PATCH 10/27] Atom no longer available --- docs/_includes/links/xdebug.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/_includes/links/xdebug.rst b/docs/_includes/links/xdebug.rst index c072665a2..e117ceb97 100644 --- a/docs/_includes/links/xdebug.rst +++ b/docs/_includes/links/xdebug.rst @@ -36,7 +36,7 @@ .. |ext_lnk_xdebug_ide_atom_php_debug| raw:: html - + php-debug From 32c7beda227dacbcc54ebad12a680cec7ce6aaff Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 22:56:36 +0100 Subject: [PATCH 11/27] Fix magento install guide links --- docs/_includes/links/examples.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/_includes/links/examples.rst b/docs/_includes/links/examples.rst index df4ecffbd..afa638a19 100644 --- a/docs/_includes/links/examples.rst +++ b/docs/_includes/links/examples.rst @@ -72,7 +72,7 @@ .. |ext_lnk_example_magento2_documentation| raw:: html - + Official Magento 2 Documentation From 3b1c0b25a50aced36a5ef7953dfca35a6941c67f Mon Sep 17 00:00:00 2001 From: cytopia Date: Fri, 23 Dec 2022 23:03:13 +0100 Subject: [PATCH 12/27] docs: fix bind links --- docs/_includes/links/documentation.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/_includes/links/documentation.rst b/docs/_includes/links/documentation.rst index c2c30b8e6..6c6b2a88f 100644 --- a/docs/_includes/links/documentation.rst +++ b/docs/_includes/links/documentation.rst @@ -12,8 +12,8 @@ .. |ext_lnk_doc_bind_soa| raw:: html - - BIND SOA + + BIND Reference .. |ext_lnk_doc_wiki_database_timezones| raw:: html From 0964c7bdd9bca76b016913829c26a38383881287 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sat, 24 Dec 2022 13:01:58 +0100 Subject: [PATCH 13/27] Fix hostnames in CHANGELOG --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a4874fa72..05f3c976f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -44,8 +44,8 @@ Once it has been tested by the community, and potential errors have been address | PHP Version | Hostname | IP address | |-------------|----------|----------------| | 5.4 | php54 | 172.16.238.201 | -| 5.5 | php54 | 172.16.238.202 | -| 5.6 | php54 | 172.16.238.203 | +| 5.5 | php55 | 172.16.238.202 | +| 5.6 | php56 | 172.16.238.203 | | 7.0 | php70 | 172.16.238.204 | | 7.1 | php71 | 172.16.238.205 | | 7.2 | php72 | 172.16.238.206 | From 0e3b963df2030cb5fc4d4135f0e07ac47e20dc5a Mon Sep 17 00:00:00 2001 From: cytopia Date: Sat, 24 Dec 2022 13:28:51 +0100 Subject: [PATCH 14/27] Do not rely on external supervisord.conf for C&C web interface --- .devilbox/www/htdocs/cnc.php | 37 +++++++++++++++++++++++++++++++----- 1 file changed, 32 insertions(+), 5 deletions(-) diff --git a/.devilbox/www/htdocs/cnc.php b/.devilbox/www/htdocs/cnc.php index 1073721c8..6a3256471 100644 --- a/.devilbox/www/htdocs/cnc.php +++ b/.devilbox/www/htdocs/cnc.php @@ -1,7 +1,30 @@ authPage(); ?> +exec('supervisorctl -c ' . $supervisor_config_file . ' ' . $command); +} + + +?> exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf restart watcherd'); + run_supervisor_command('restart watcherd'); + //loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf restart watcherd'); sleep(1); loadClass('Helper')->redirect('/cnc.php'); } @@ -24,8 +47,10 @@
exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status watcherd'); - $status_h = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status httpd'); + $status_w = run_supervisor_command('status watcherd'); + $status_h = run_supervisor_command('status httpd'); + //$status_w = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status watcherd'); + //$status_h = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status httpd'); $words = preg_split("/\s+/", $status_w); $data_w = array( @@ -77,13 +102,15 @@

watcherd stderr


exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd stderr'); + $output = run_supervisor_command('tail -1000000 watcherd stderr'); + //$output = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd stderr'); echo '
' . $output . '
'; ?>

watcherd stdout


exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd'); + $output = run_supervisor_command('tail -1000000 watcherd'); + //$output = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd'); echo '
' . $output . '
'; ?> From 55f0447ce107a9b4fe47a9a5603db75be8565a31 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 15:40:45 +0100 Subject: [PATCH 15/27] Add some colored output for logs in C&C --- .devilbox/www/htdocs/cnc.php | 55 +++++++++++++++++++++++++----------- 1 file changed, 39 insertions(+), 16 deletions(-) diff --git a/.devilbox/www/htdocs/cnc.php b/.devilbox/www/htdocs/cnc.php index 6a3256471..92da0f25e 100644 --- a/.devilbox/www/htdocs/cnc.php +++ b/.devilbox/www/htdocs/cnc.php @@ -24,7 +24,6 @@ function run_supervisor_command($command) { ?> exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf restart watcherd'); sleep(1); loadClass('Helper')->redirect('/cnc.php'); } @@ -49,22 +48,20 @@ function run_supervisor_command($command) { exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status watcherd'); - //$status_h = loadClass('Helper')->exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf status httpd'); $words = preg_split("/\s+/", $status_w); $data_w = array( - 'name' => $words[0], - 'state' => $words[1], - 'pid' => preg_replace('/,$/', '', $words[3]), - 'uptime' => $words[5], + 'name' => isset($words[0]) ? $words[0] : '', + 'state' => isset($words[1]) ? $words[1] : '', + 'pid' => isset($words[3]) ? preg_replace('/,$/', '', $words[3]) : '', + 'uptime' => isset($words[5]) ? $words[5] : '', ); $words = preg_split("/\s+/", $status_h); $data_h = array( - 'name' => $words[0], - 'state' => $words[1], - 'pid' => preg_replace('/,$/', '', $words[3]), - 'uptime' => $words[5], + 'name' => isset($words[0]) ? $words[0] : '', + 'state' => isset($words[1]) ? $words[1] : '', + 'pid' => isset($words[3]) ? preg_replace('/,$/', '', $words[3]) : '', + 'uptime' => isset($words[5]) ? $words[5] : '', ); ?>

Daemon overview


@@ -103,15 +100,41 @@ function run_supervisor_command($command) {
exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd stderr'); - echo '
' . $output . '
'; + echo '
';
+						foreach(preg_split("/((\r?\n)|(\r\n?))/", $output) as $line) {
+							if ( strpos($line, "[ERR]") !== false ) {
+								echo '' . $line . '';
+							} else if ( strpos($line, "[emerg]") !== false ) {
+								echo '' . $line . '';
+							} else if ( strpos($line, "Syntax error") !== false ) {
+								echo '' . $line . '';
+							} else if ( strpos($line, "[WARN]") !== false ) {
+								echo '' . $line . '';
+							} else {
+								echo $line;
+							}
+							echo "\n";
+						}
+						echo '
'; ?>

watcherd stdout


- exec('supervisorctl -c /etc/supervisor/custom.d/supervisorctl.conf tail -1000000 watcherd'); - echo '
' . $output . '
'; + echo '
';
+						foreach(preg_split("/((\r?\n)|(\r\n?))/", $output) as $line) {
+							$pos_info = strpos($line, "[INFO]");
+							$pos_ok   = strpos($line, "[OK]");
+							if ( $pos_ok !== false ) {
+								echo '' . $line . '';
+							} else if ( $pos_info !== false && $pos_info == 0 ) {
+								echo '' . $line . '';
+							} else {
+								echo $line;
+							}
+							echo "\n";
+						}
+						echo '
'; ?>
From c64c4553d7430d95c3078463d3a74cf1319398c0 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 15:41:21 +0100 Subject: [PATCH 16/27] Remove obsolete mounts from docker-compose --- compose/docker-compose.override.yml-php-multi.yml | 10 ---------- docker-compose.yml | 4 ---- 2 files changed, 14 deletions(-) diff --git a/compose/docker-compose.override.yml-php-multi.yml b/compose/docker-compose.override.yml-php-multi.yml index 12bcc31a0..ca9b3fa61 100644 --- a/compose/docker-compose.override.yml-php-multi.yml +++ b/compose/docker-compose.override.yml-php-multi.yml @@ -48,26 +48,16 @@ x-app: &default-php # to overwrite the default PHP-FPM configuration - ${DEVILBOX_PATH}/cfg/php-fpm-${PHP_SERVER}:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} - # Mount devilbox user-defined *.so files in order - # to load custom PHP modules - - ${DEVILBOX_PATH}/mod/php-fpm-${PHP_SERVER}:/usr/lib64/php/custom-modules:ro${MOUNT_OPTIONS} - # Mount devilbox user-defined PHP-FPM startup *.sh scripts - ${DEVILBOX_PATH}/cfg/php-startup-${PHP_SERVER}:/startup.1.d:rw${MOUNT_OPTIONS} - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} - # Mount devilbox user-defined bash config - - ${DEVILBOX_PATH}/bash:/etc/bashrc-devilbox.d:rw${MOUNT_OPTIONS} - # Mount devilbox user-defined supervisord config - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} # Certificate Authority public key - ${DEVILBOX_PATH}/ca:/ca:rw${MOUNT_OPTIONS} - # Users SSH directory (read-only) - - ${HOST_PATH_SSH_DIR}:/home/devilbox/.ssh:ro${MOUNT_OPTIONS} - depends_on: - bind diff --git a/docker-compose.yml b/docker-compose.yml index 63e31b44f..ecc62d001 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -203,10 +203,6 @@ services: # to overwrite the default PHP-FPM configuration - ${DEVILBOX_PATH}/cfg/php-fpm-${PHP_SERVER}:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} - # Mount devilbox user-defined *.so files in order - # to load custom PHP modules - - ${DEVILBOX_PATH}/mod/php-fpm-${PHP_SERVER}:/usr/lib64/php/custom-modules:ro${MOUNT_OPTIONS} - # Mount devilbox user-defined PHP-FPM startup *.sh scripts - ${DEVILBOX_PATH}/cfg/php-startup-${PHP_SERVER}:/startup.1.d:rw${MOUNT_OPTIONS} - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} From d5858da3e0f2e66b2f228325c21cfeba26366c85 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 15:42:10 +0100 Subject: [PATCH 17/27] Fix indentation --- .devilbox/www/htdocs/cnc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devilbox/www/htdocs/cnc.php b/.devilbox/www/htdocs/cnc.php index 92da0f25e..2a78c7cf2 100644 --- a/.devilbox/www/htdocs/cnc.php +++ b/.devilbox/www/htdocs/cnc.php @@ -119,7 +119,7 @@ function run_supervisor_command($command) { ?>

watcherd stdout


- '; foreach(preg_split("/((\r?\n)|(\r\n?))/", $output) as $line) { From e60aa4e4651e7adaba6e4d234e971d05d8827c77 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 15:59:57 +0100 Subject: [PATCH 18/27] Remove obsolete points from README --- README.md | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 7607a45f3..b4a429021 100644 --- a/README.md +++ b/README.md @@ -377,7 +377,7 @@ Every single attachable container comes with many different versions. In order t - 8.2[2] + 8.2 @@ -391,7 +391,7 @@ Every single attachable container comes with many different versions. In order t [1] PHP 5.2 is available to use, but it is not officially supported. The Devilbox intranet does not work with this version as PHP 5.2 does not support namespaces. Furthermore PHP 5.2 does only work with Apache 2.4, Nginx stable and Nginx mainline. It does not work with Apache 2.2. Use at your own risk. -[2] PHP 8.2 is an upcoming unreleased versions of PHP, which is directly built out of their [official git branches](https://github.com/php/php-src/) every night to assure you will leverage their latest features. + > **Documentation:** > [Change container versions](https://devilbox.readthedocs.io/en/latest/getting-started/change-container-versions.html) @@ -558,10 +558,6 @@ The Devilbox has everything setup for you. The only thing you will have to insta :star: Custom PHP config Overwrite any setting for PHP. - - :star: Custom PHP modules - Load custom PHP modules on the fly. - :star: Email catch-all All outgoing emails are catched and will be presented in the included intranet. @@ -611,7 +607,7 @@ The following batteries are available in the Devilbox intranet by default: phpMyAdmin phpPgAdmin phpRedMin - PHPMemcached Admin + PHP Memcached Admin OpCache GUI Mail viewer @@ -647,10 +643,6 @@ The following tools will assist you on creating new projects easily as well as h :wrench: linkcheck linkcheck is a command line tool that searches for URLs in files (optionally limited by extension) and validates their HTTP status code. - - :wrench: homebrew - brew is a MacOS Homenbrew for Linux. - :wrench: markdownlint markdownlint is a markdown linter. @@ -708,11 +700,9 @@ The following tools will assist you on creating new projects easily as well as h Well-known and popular tools will be at your service as well: -Devilbox Devilbox Devilbox Devilbox -Devilbox Devilbox Devilbox Devilbox @@ -856,10 +846,6 @@ PHP modules can be enabled or disabled on demand to reflect the state of your ta > **Documentation:** > [Enable/disable PHP modules](https://devilbox.readthedocs.io/en/latest/intermediate/enable-disable-php-modules.html) -#### Custom PHP Modules - -You can also copy any custom modules into `mod/(php-fpm)-` and add a custom `*.ini` file to load them. - #### Supported PHP Frameworks As far as tested there are no limitations and you can use any Framework or CMS just as you would on your live environment. Below are a few examples of extensively tested Frameworks and CMS: @@ -980,6 +966,7 @@ To increase visibility and bug-free operation: * Star this project * Open up issues for bugs and feature requests * Clone this project and submit fixes or features +* Visit the [Devilbox Discord Chat](https://discord.gg/2wP3V6kBj4) to exchange about setups * Visit the [Devilbox Community Forums](https://devilbox.discourse.group) for announcements and to help others Additionally you can [subscribe to Devilbox on CodeTriage](https://www.codetriage.com/cytopia/devilbox), From a560926315765ed3e0f2633bf37a277b4442f261 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 16:48:15 +0100 Subject: [PATCH 19/27] Removed obsolete supervisorctl config section --- CHANGELOG.md | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 05f3c976f..7288155cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,18 +55,6 @@ Once it has been tested by the community, and potential errors have been address | 8.1 | php81 | 172.16.238.210 | | 8.2 | php82 | 172.16.238.211 | -### Important - -Currently the Intranet Command and Control Center is not yet self sufficient as it requires a supervisord configuration file. - -In the root of the Devilbox repository, add `supervisorctl.conf` into `supervisor/` directory. **Important:** It must have this name. -```ini -[supervisorctl] -serverurl=http://httpd:9001 -username=supervisord -password=mypassword -``` - ### Fixed - Fixed Protocol substitution bug in Reverse Proxy generation for Apache 2.2 and Apache 2.4 [vhost-gen #49](https://github.com/devilbox/vhost-gen/pull/49) [vhost-gen #50](https://github.com/devilbox/vhost-gen/pull/50) - Fixed missing module `mod_proxy_html` in Apache 2.4 as per requirement from `vhost-gen` for Reverse Proxy setup From 98f05d7570ba90aac9706e1164d6d8b82a689f5b Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 16:48:32 +0100 Subject: [PATCH 20/27] Updated UPDATING.md --- UPDATING.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/UPDATING.md b/UPDATING.md index 77e2cd689..c4e3cd0c8 100644 --- a/UPDATING.md +++ b/UPDATING.md @@ -3,6 +3,17 @@ This document will hold all information on how to update between major versions. +## Update from `v2.4.0` to `v3.0.0` (`v3.0.0-beta-1`) + +**PR:** https://github.com/cytopia/devilbox/pull/942 + +This PR introduces new `.env` variables, so you are required to copy `env-example` over to `.env`. +Also ensure to stop and remove containers. +```bash +docker-compose stop +docker-compose rm -f +``` + ## Update from `v1.8.1` to `v1.8.2` **PR:** https://github.com/cytopia/devilbox/pull/750 From dfda00d78a633d161f7d4ed9a284aefb0af6e950 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 16:48:46 +0100 Subject: [PATCH 21/27] Pinned HTTPD images --- docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index ecc62d001..29b0fa8fe 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -227,7 +227,7 @@ services: # Web Server # ------------------------------------------------------------ httpd: - image: devilbox/${HTTPD_SERVER}:${HTTPD_FLAVOUR:-alpine}-release-0.49b + image: devilbox/${HTTPD_SERVER}:${HTTPD_FLAVOUR:-alpine}-1.0-beta1 hostname: httpd environment: From 8b0788b403f2eee7c0acc466c33eecf78c8c083b Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 17:37:58 +0100 Subject: [PATCH 22/27] Add PHP version number to README files in cfg/ dir --- cfg/php-fpm-5.3/README.md | 2 +- cfg/php-fpm-5.4/README.md | 2 +- cfg/php-fpm-5.5/README.md | 2 +- cfg/php-fpm-5.6/README.md | 2 +- cfg/php-fpm-7.0/README.md | 2 +- cfg/php-fpm-7.1/README.md | 2 +- cfg/php-fpm-7.2/README.md | 2 +- cfg/php-fpm-7.3/README.md | 2 +- cfg/php-fpm-7.4/README.md | 2 +- cfg/php-fpm-8.0/README.md | 2 +- cfg/php-fpm-8.1/README.md | 2 +- cfg/php-fpm-8.2/README.md | 2 +- cfg/php-ini-5.2/README.md | 2 +- cfg/php-ini-5.3/README.md | 2 +- cfg/php-ini-5.4/README.md | 2 +- cfg/php-ini-5.5/README.md | 2 +- cfg/php-ini-5.6/README.md | 2 +- cfg/php-ini-7.0/README.md | 2 +- cfg/php-ini-7.1/README.md | 2 +- cfg/php-ini-7.2/README.md | 2 +- cfg/php-ini-7.3/README.md | 2 +- cfg/php-ini-7.4/README.md | 2 +- cfg/php-ini-8.0/README.md | 2 +- cfg/php-ini-8.1/README.md | 2 +- cfg/php-ini-8.2/README.md | 2 +- cfg/php-startup-5.2/README.md | 2 +- cfg/php-startup-5.3/README.md | 2 +- cfg/php-startup-5.4/README.md | 2 +- cfg/php-startup-5.5/README.md | 2 +- cfg/php-startup-5.6/README.md | 2 +- cfg/php-startup-7.0/README.md | 2 +- cfg/php-startup-7.1/README.md | 2 +- cfg/php-startup-7.2/README.md | 2 +- cfg/php-startup-7.3/README.md | 2 +- cfg/php-startup-7.4/README.md | 2 +- cfg/php-startup-8.0/README.md | 2 +- cfg/php-startup-8.1/README.md | 2 +- cfg/php-startup-8.2/README.md | 2 +- 38 files changed, 38 insertions(+), 38 deletions(-) diff --git a/cfg/php-fpm-5.3/README.md b/cfg/php-fpm-5.3/README.md index db30d63f9..6b8c35c15 100644 --- a/cfg/php-fpm-5.3/README.md +++ b/cfg/php-fpm-5.3/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 5.3 config directory ## General diff --git a/cfg/php-fpm-5.4/README.md b/cfg/php-fpm-5.4/README.md index db30d63f9..29fc29cad 100644 --- a/cfg/php-fpm-5.4/README.md +++ b/cfg/php-fpm-5.4/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 5.4 config directory ## General diff --git a/cfg/php-fpm-5.5/README.md b/cfg/php-fpm-5.5/README.md index db30d63f9..b9dc846e6 100644 --- a/cfg/php-fpm-5.5/README.md +++ b/cfg/php-fpm-5.5/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 5.5 config directory ## General diff --git a/cfg/php-fpm-5.6/README.md b/cfg/php-fpm-5.6/README.md index db30d63f9..a6253feba 100644 --- a/cfg/php-fpm-5.6/README.md +++ b/cfg/php-fpm-5.6/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 5.6 config directory ## General diff --git a/cfg/php-fpm-7.0/README.md b/cfg/php-fpm-7.0/README.md index db30d63f9..8d3d6c59d 100644 --- a/cfg/php-fpm-7.0/README.md +++ b/cfg/php-fpm-7.0/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 7.0 config directory ## General diff --git a/cfg/php-fpm-7.1/README.md b/cfg/php-fpm-7.1/README.md index db30d63f9..a957e5827 100644 --- a/cfg/php-fpm-7.1/README.md +++ b/cfg/php-fpm-7.1/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 7.1 config directory ## General diff --git a/cfg/php-fpm-7.2/README.md b/cfg/php-fpm-7.2/README.md index db30d63f9..8b51991c0 100644 --- a/cfg/php-fpm-7.2/README.md +++ b/cfg/php-fpm-7.2/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 7.2 config directory ## General diff --git a/cfg/php-fpm-7.3/README.md b/cfg/php-fpm-7.3/README.md index db30d63f9..9590636fb 100644 --- a/cfg/php-fpm-7.3/README.md +++ b/cfg/php-fpm-7.3/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 7.3 config directory ## General diff --git a/cfg/php-fpm-7.4/README.md b/cfg/php-fpm-7.4/README.md index db30d63f9..4801157bb 100644 --- a/cfg/php-fpm-7.4/README.md +++ b/cfg/php-fpm-7.4/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 7.4 config directory ## General diff --git a/cfg/php-fpm-8.0/README.md b/cfg/php-fpm-8.0/README.md index db30d63f9..93861e41a 100644 --- a/cfg/php-fpm-8.0/README.md +++ b/cfg/php-fpm-8.0/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 8.0 config directory ## General diff --git a/cfg/php-fpm-8.1/README.md b/cfg/php-fpm-8.1/README.md index db30d63f9..838a0fdda 100644 --- a/cfg/php-fpm-8.1/README.md +++ b/cfg/php-fpm-8.1/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 8.1 config directory ## General diff --git a/cfg/php-fpm-8.2/README.md b/cfg/php-fpm-8.2/README.md index db30d63f9..20cafb48f 100644 --- a/cfg/php-fpm-8.2/README.md +++ b/cfg/php-fpm-8.2/README.md @@ -1,4 +1,4 @@ -# PHP-FPM config directory +# PHP-FPM 8.2 config directory ## General diff --git a/cfg/php-ini-5.2/README.md b/cfg/php-ini-5.2/README.md index b967fcaa0..a3882782a 100644 --- a/cfg/php-ini-5.2/README.md +++ b/cfg/php-ini-5.2/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 5.2 ini directory ## General diff --git a/cfg/php-ini-5.3/README.md b/cfg/php-ini-5.3/README.md index b967fcaa0..249241049 100644 --- a/cfg/php-ini-5.3/README.md +++ b/cfg/php-ini-5.3/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 5.3 ini directory ## General diff --git a/cfg/php-ini-5.4/README.md b/cfg/php-ini-5.4/README.md index b967fcaa0..6e899f518 100644 --- a/cfg/php-ini-5.4/README.md +++ b/cfg/php-ini-5.4/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 5.4 ini directory ## General diff --git a/cfg/php-ini-5.5/README.md b/cfg/php-ini-5.5/README.md index b967fcaa0..3d35d1fc4 100644 --- a/cfg/php-ini-5.5/README.md +++ b/cfg/php-ini-5.5/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 5.5 ini directory ## General diff --git a/cfg/php-ini-5.6/README.md b/cfg/php-ini-5.6/README.md index b045e97aa..5639d787f 100644 --- a/cfg/php-ini-5.6/README.md +++ b/cfg/php-ini-5.6/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 5.6 ini directory ## General diff --git a/cfg/php-ini-7.0/README.md b/cfg/php-ini-7.0/README.md index b045e97aa..8912cbfba 100644 --- a/cfg/php-ini-7.0/README.md +++ b/cfg/php-ini-7.0/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 7.0 ini directory ## General diff --git a/cfg/php-ini-7.1/README.md b/cfg/php-ini-7.1/README.md index b045e97aa..488ea05a5 100644 --- a/cfg/php-ini-7.1/README.md +++ b/cfg/php-ini-7.1/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 7.1 ini directory ## General diff --git a/cfg/php-ini-7.2/README.md b/cfg/php-ini-7.2/README.md index b045e97aa..52fd25052 100644 --- a/cfg/php-ini-7.2/README.md +++ b/cfg/php-ini-7.2/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 7.2 ini directory ## General diff --git a/cfg/php-ini-7.3/README.md b/cfg/php-ini-7.3/README.md index b045e97aa..518a35863 100644 --- a/cfg/php-ini-7.3/README.md +++ b/cfg/php-ini-7.3/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 7.3 ini directory ## General diff --git a/cfg/php-ini-7.4/README.md b/cfg/php-ini-7.4/README.md index b967fcaa0..bb2235c7e 100644 --- a/cfg/php-ini-7.4/README.md +++ b/cfg/php-ini-7.4/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 7.4 ini directory ## General diff --git a/cfg/php-ini-8.0/README.md b/cfg/php-ini-8.0/README.md index b967fcaa0..85366e216 100644 --- a/cfg/php-ini-8.0/README.md +++ b/cfg/php-ini-8.0/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 8.0 ini directory ## General diff --git a/cfg/php-ini-8.1/README.md b/cfg/php-ini-8.1/README.md index b967fcaa0..19f76673c 100644 --- a/cfg/php-ini-8.1/README.md +++ b/cfg/php-ini-8.1/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 8.1 ini directory ## General diff --git a/cfg/php-ini-8.2/README.md b/cfg/php-ini-8.2/README.md index b967fcaa0..94ddf62ed 100644 --- a/cfg/php-ini-8.2/README.md +++ b/cfg/php-ini-8.2/README.md @@ -1,4 +1,4 @@ -# PHP ini directory +# PHP 8.2 ini directory ## General diff --git a/cfg/php-startup-5.2/README.md b/cfg/php-startup-5.2/README.md index e212252ea..17b5bd75c 100644 --- a/cfg/php-startup-5.2/README.md +++ b/cfg/php-startup-5.2/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 5.2 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-5.3/README.md b/cfg/php-startup-5.3/README.md index e212252ea..6e6f07df4 100644 --- a/cfg/php-startup-5.3/README.md +++ b/cfg/php-startup-5.3/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 5.3 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-5.4/README.md b/cfg/php-startup-5.4/README.md index e212252ea..ad492ab60 100644 --- a/cfg/php-startup-5.4/README.md +++ b/cfg/php-startup-5.4/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 5.4 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-5.5/README.md b/cfg/php-startup-5.5/README.md index e212252ea..45a17bb88 100644 --- a/cfg/php-startup-5.5/README.md +++ b/cfg/php-startup-5.5/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 5.5 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-5.6/README.md b/cfg/php-startup-5.6/README.md index e212252ea..a12fed0ae 100644 --- a/cfg/php-startup-5.6/README.md +++ b/cfg/php-startup-5.6/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 5.6 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-7.0/README.md b/cfg/php-startup-7.0/README.md index e212252ea..0fb98c2e6 100644 --- a/cfg/php-startup-7.0/README.md +++ b/cfg/php-startup-7.0/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 7.0 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-7.1/README.md b/cfg/php-startup-7.1/README.md index e212252ea..c2fc1f4c0 100644 --- a/cfg/php-startup-7.1/README.md +++ b/cfg/php-startup-7.1/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 7.1 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-7.2/README.md b/cfg/php-startup-7.2/README.md index e212252ea..f4cad33be 100644 --- a/cfg/php-startup-7.2/README.md +++ b/cfg/php-startup-7.2/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 7.2 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-7.3/README.md b/cfg/php-startup-7.3/README.md index e212252ea..2018e87db 100644 --- a/cfg/php-startup-7.3/README.md +++ b/cfg/php-startup-7.3/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 7.3 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-7.4/README.md b/cfg/php-startup-7.4/README.md index e212252ea..8796aef9b 100644 --- a/cfg/php-startup-7.4/README.md +++ b/cfg/php-startup-7.4/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 7.4 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-8.0/README.md b/cfg/php-startup-8.0/README.md index e212252ea..8589ffded 100644 --- a/cfg/php-startup-8.0/README.md +++ b/cfg/php-startup-8.0/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 8.0 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-8.1/README.md b/cfg/php-startup-8.1/README.md index e212252ea..789124a5e 100644 --- a/cfg/php-startup-8.1/README.md +++ b/cfg/php-startup-8.1/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 8.1 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires diff --git a/cfg/php-startup-8.2/README.md b/cfg/php-startup-8.2/README.md index e212252ea..8ceb5408e 100644 --- a/cfg/php-startup-8.2/README.md +++ b/cfg/php-startup-8.2/README.md @@ -1,4 +1,4 @@ -# Custom startup scripts (per PHP version) +# Custom startup scripts (for PHP 8.2 only) Any script inside this directory ending by `.sh` will be executed during the PHP container startup. This is useful to apply your custom settings such as installing software that usually requires From 200f6ce0b19e92f6d01f2ae4570b6fe086495b2d Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 17:38:40 +0100 Subject: [PATCH 23/27] Fix volume paths in php-multi compose files --- .../docker-compose.override.yml-php-multi.yml | 158 +++++++++++++----- 1 file changed, 117 insertions(+), 41 deletions(-) diff --git a/compose/docker-compose.override.yml-php-multi.yml b/compose/docker-compose.override.yml-php-multi.yml index ca9b3fa61..96cde440e 100644 --- a/compose/docker-compose.override.yml-php-multi.yml +++ b/compose/docker-compose.override.yml-php-multi.yml @@ -6,58 +6,23 @@ version: '2.3' # Yaml Default # ------------------------------------------------------------ +### +### Default PHP-FPM config +### x-app: &default-php env_file: - ./.env - environment: - ## - ## Debug/Logging - ## + # Debug/Logging - DEBUG_ENTRYPOINT=${DEBUG_ENTRYPOINT:-2} - DOCKER_LOGS=1 - - ## - ## Enable/Disable PHP Modules - ## + # Enable/Disable PHP Modules - ENABLE_MODULES=${PHP_MODULES_ENABLE} - DISABLE_MODULES=${PHP_MODULES_DISABLE} - - ## - ## Mail-catching - ## + # Mail-catching - ENABLE_MAIL=${PHP_MAIL_CATCH_ALL:-2} dns: - 172.16.238.100 - - volumes: - # ---- Format: ---- - # HOST-DIRECTORY : DOCKER-DIRECTORY - - # Mount custom mass virtual hosting - - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} - - # Mount Mail directory - - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} - - # Mount devilbox user-defined *.ini files in order - # to overwrite the default PHP.ini configuration - - ${DEVILBOX_PATH}/cfg/php-ini-${PHP_SERVER}:/etc/php-custom.d:ro${MOUNT_OPTIONS} - - # Mount devilbox user-defined PHP-FPM *.conf files in order - # to overwrite the default PHP-FPM configuration - - ${DEVILBOX_PATH}/cfg/php-fpm-${PHP_SERVER}:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} - - # Mount devilbox user-defined PHP-FPM startup *.sh scripts - - ${DEVILBOX_PATH}/cfg/php-startup-${PHP_SERVER}:/startup.1.d:rw${MOUNT_OPTIONS} - - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} - - # Mount devilbox user-defined supervisord config - - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} - - # Certificate Authority public key - - ${DEVILBOX_PATH}/ca:/ca:rw${MOUNT_OPTIONS} - depends_on: - bind @@ -66,6 +31,7 @@ x-app: &default-php # PHP Services # ------------------------------------------------------------ services: + php54: <<: *default-php image: devilbox/php-fpm:5.4-prod-0.147 @@ -73,6 +39,16 @@ services: networks: app_net: ipv4_address: 172.16.238.201 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-5.4:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-5.4:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-5.4:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php55: <<: *default-php @@ -81,6 +57,16 @@ services: networks: app_net: ipv4_address: 172.16.238.202 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-5.5:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-5.5:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-5.5:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php56: <<: *default-php @@ -89,6 +75,16 @@ services: networks: app_net: ipv4_address: 172.16.238.203 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-5.6:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-5.6:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-5.6:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php70: <<: *default-php @@ -97,6 +93,16 @@ services: networks: app_net: ipv4_address: 172.16.238.204 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-7.0:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-7.0:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-7.0:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php71: <<: *default-php @@ -105,6 +111,16 @@ services: networks: app_net: ipv4_address: 172.16.238.205 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-7.1:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-7.1:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-7.1:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php72: <<: *default-php @@ -113,6 +129,16 @@ services: networks: app_net: ipv4_address: 172.16.238.206 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-7.2:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-7.2:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-7.2:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php73: <<: *default-php @@ -121,6 +147,16 @@ services: networks: app_net: ipv4_address: 172.16.238.207 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-7.3:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-7.3:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-7.3:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php74: <<: *default-php @@ -129,6 +165,16 @@ services: networks: app_net: ipv4_address: 172.16.238.208 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-7.4:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-7.4:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-7.4:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php80: <<: *default-php @@ -137,6 +183,16 @@ services: networks: app_net: ipv4_address: 172.16.238.209 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-8.0:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-8.0:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-8.0:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php81: <<: *default-php @@ -145,6 +201,16 @@ services: networks: app_net: ipv4_address: 172.16.238.210 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-8.1:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-8.1:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-8.1:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} php82: <<: *default-php @@ -153,3 +219,13 @@ services: networks: app_net: ipv4_address: 172.16.238.211 + volumes: + # Specific volumes + - ${DEVILBOX_PATH}/cfg/php-ini-8.2:/etc/php-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-fpm-8.2:/etc/php-fpm-custom.d:ro${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/cfg/php-startup-8.2:/startup.1.d:rw${MOUNT_OPTIONS} + # Generic volumes + - ${HOST_PATH_HTTPD_DATADIR}:/shared/httpd:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/supervisor:/etc/supervisor/custom.d:rw${MOUNT_OPTIONS} + - ${DEVILBOX_PATH}/autostart:/startup.2.d:rw${MOUNT_OPTIONS} + - devilbox-mail:/var/mail:rw${MOUNT_OPTIONS} From ffba5d61b757f716309c7d93f9d625f777dd1272 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 17:40:02 +0100 Subject: [PATCH 24/27] Remove obsolete mod/ directory --- mod/README.md | 3 --- mod/php-fpm-5.2/.keepme | 0 mod/php-fpm-5.3/.keepme | 0 mod/php-fpm-5.4/.keepme | 0 mod/php-fpm-5.5/.keepme | 0 mod/php-fpm-5.6/.keepme | 0 mod/php-fpm-7.0/.keepme | 0 mod/php-fpm-7.1/.keepme | 0 mod/php-fpm-7.2/.keepme | 0 mod/php-fpm-7.3/.keepme | 0 mod/php-fpm-7.4/.keepme | 0 mod/php-fpm-8.0/.keepme | 0 mod/php-fpm-8.1/.keepme | 0 mod/php-fpm-8.2/.keepme | 0 14 files changed, 3 deletions(-) delete mode 100644 mod/README.md delete mode 100644 mod/php-fpm-5.2/.keepme delete mode 100644 mod/php-fpm-5.3/.keepme delete mode 100644 mod/php-fpm-5.4/.keepme delete mode 100644 mod/php-fpm-5.5/.keepme delete mode 100644 mod/php-fpm-5.6/.keepme delete mode 100644 mod/php-fpm-7.0/.keepme delete mode 100644 mod/php-fpm-7.1/.keepme delete mode 100644 mod/php-fpm-7.2/.keepme delete mode 100644 mod/php-fpm-7.3/.keepme delete mode 100644 mod/php-fpm-7.4/.keepme delete mode 100644 mod/php-fpm-8.0/.keepme delete mode 100644 mod/php-fpm-8.1/.keepme delete mode 100644 mod/php-fpm-8.2/.keepme diff --git a/mod/README.md b/mod/README.md deleted file mode 100644 index 770666b17..000000000 --- a/mod/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# Devilbox user-defined PHP modules - -Use this folders to add your custom PHP modules. diff --git a/mod/php-fpm-5.2/.keepme b/mod/php-fpm-5.2/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-5.3/.keepme b/mod/php-fpm-5.3/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-5.4/.keepme b/mod/php-fpm-5.4/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-5.5/.keepme b/mod/php-fpm-5.5/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-5.6/.keepme b/mod/php-fpm-5.6/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-7.0/.keepme b/mod/php-fpm-7.0/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-7.1/.keepme b/mod/php-fpm-7.1/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-7.2/.keepme b/mod/php-fpm-7.2/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-7.3/.keepme b/mod/php-fpm-7.3/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-7.4/.keepme b/mod/php-fpm-7.4/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-8.0/.keepme b/mod/php-fpm-8.0/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-8.1/.keepme b/mod/php-fpm-8.1/.keepme deleted file mode 100644 index e69de29bb..000000000 diff --git a/mod/php-fpm-8.2/.keepme b/mod/php-fpm-8.2/.keepme deleted file mode 100644 index e69de29bb..000000000 From 10571f7b518bdbb8080da2406b4e6f9696ea13ba Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 18:06:35 +0100 Subject: [PATCH 25/27] Intranet: Show backend type on vhost page --- .devilbox/www/htdocs/vhosts.php | 4 ++- .devilbox/www/include/lib/container/Httpd.php | 28 +++++++++++++++++++ CHANGELOG.md | 1 + 3 files changed, 32 insertions(+), 1 deletion(-) diff --git a/.devilbox/www/htdocs/vhosts.php b/.devilbox/www/htdocs/vhosts.php index 9f643c5cd..03590772f 100644 --- a/.devilbox/www/htdocs/vhosts.php +++ b/.devilbox/www/htdocs/vhosts.php @@ -24,6 +24,7 @@ Project DocumentRoot + Backend Config Valid URL @@ -31,7 +32,7 @@ getEnv('HOST_PATH_HTTPD_DATADIR');?>//getEnv('HTTPD_DOCROOT_DIR');?> + getVhostBackend($vHost['name']); ?> getVhostgenTemplatePath($vHost['name'])) !== false): ?> diff --git a/.devilbox/www/include/lib/container/Httpd.php b/.devilbox/www/include/lib/container/Httpd.php index 7813ec851..96e025409 100644 --- a/.devilbox/www/include/lib/container/Httpd.php +++ b/.devilbox/www/include/lib/container/Httpd.php @@ -196,6 +196,34 @@ public function getVhostgenTemplatePath($vhost) return false; } + public function getVhostBackend($vhost) + { + $dir = loadClass('Helper')->getEnv('HTTPD_TEMPLATE_DIR'); + $name = 'backend.cfg'; + $file = '/shared/httpd/'.$vhost.'/'.$dir.'/'.$name; + if (!file_exists($file)) { + return 'default'; + } + + $fp = fopen($file, 'r'); + $cont = stream_get_contents($fp); + fclose($fp); + + // conf:::: + $arr = explode(':', $cont); + + $type = $arr[1]; + $prot = $arr[2]; + $addr = ''; + for ($i=3; $i<(count($arr)-1); $i++) { + $addr .= $arr[$i]; + } + $addr = $arr[3]; // this may contain ':' itself + $port = $arr[count($arr) - 1]; + + return $prot.'://'.$addr.':'.$port; + } + /********************************************************************************* * diff --git a/CHANGELOG.md b/CHANGELOG.md index 7288155cd..eb99881ba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -64,6 +64,7 @@ Once it has been tested by the community, and potential errors have been address ### Added - New HTTPD server capable of auto reverse proxy creation (and different PHP versions per project) - Intranet: Added Command & Control center to view watcherd logs and retrigger config in case of vhost changes +- Intranet: vhost page now also shows the configured Backend - Environment variable `DEVILBOX_HTTPD_MGMT_PASS` - Environment variable `DEVILBOX_HTTPD_MGMT_USER` - New Docker Compose Override file `docker-compose.override.yml-php-multi.yml` (allows to run multiple PHP versions). From 025b45c48c60fec1a381adb779f1a62f46ccbbba Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 18:11:25 +0100 Subject: [PATCH 26/27] Fix IPv6 handling --- .devilbox/www/include/lib/container/Httpd.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.devilbox/www/include/lib/container/Httpd.php b/.devilbox/www/include/lib/container/Httpd.php index 96e025409..1d52bd288 100644 --- a/.devilbox/www/include/lib/container/Httpd.php +++ b/.devilbox/www/include/lib/container/Httpd.php @@ -214,11 +214,10 @@ public function getVhostBackend($vhost) $type = $arr[1]; $prot = $arr[2]; - $addr = ''; + $addr = ''; // this may contain ':' itself due to IPv6 addresses for ($i=3; $i<(count($arr)-1); $i++) { $addr .= $arr[$i]; } - $addr = $arr[3]; // this may contain ':' itself $port = $arr[count($arr) - 1]; return $prot.'://'.$addr.':'.$port; From 3ffb360c51e941d730137b1d4f1abcb687bedf71 Mon Sep 17 00:00:00 2001 From: cytopia Date: Sun, 25 Dec 2022 18:41:26 +0100 Subject: [PATCH 27/27] Update check-config.sh --- check-config.sh | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/check-config.sh b/check-config.sh index c2d869ffe..e39d6bd1a 100755 --- a/check-config.sh +++ b/check-config.sh @@ -430,7 +430,7 @@ fi #-------------------------------------------------------------------------------------------------- -# Ensure cfg/, mod/ and log/ directories exist +# Ensure cfg/ and log/ directories exist #-------------------------------------------------------------------------------------------------- print_head_1 "Checking required Devilbox core directories exist" @@ -464,21 +464,6 @@ if [ "${DIR_MISSING}" = "0" ]; then log_ok "All PHP log/ sub directories are present" fi -# /mod/php-fpm-VERSION -DIR_MISSING=0 -while read -r php_version; do - if [ ! -d "mod/php-fpm-${php_version}" ]; then - log_err "Directory 'mod/php-fpm-${php_version}' is missing" - RET_CODE=$(( RET_CODE + 1)) - DIR_MISSING=1 - else - log_debug "Directory 'mod/php-fpm-${php_version}' is present" - fi -done < <(grep -E '^#?PHP_SERVER=' env-example | awk -F'=' '{print $2}') -if [ "${DIR_MISSING}" = "0" ]; then - log_ok "All PHP mod/ sub directories are present" -fi - # /cfg/apache|nginx-VERSION DIR_MISSING=0 while read -r httpd_version; do @@ -522,7 +507,6 @@ DEVILBOX_DIRS=( "cfg" "compose" "log" - "mod" "supervisor" ) @@ -591,7 +575,6 @@ DEVILBOX_DIRS=( "ca" "cfg" "compose" - "mod" "supervisor" )