diff --git a/.devilbox/www/config.php b/.devilbox/www/config.php index 81321044..59ca653f 100644 --- a/.devilbox/www/config.php +++ b/.devilbox/www/config.php @@ -13,8 +13,8 @@ error_reporting(-1); putenv('RES_OPTIONS=retrans:1 retry:1 timeout:1 attempts:1'); -$DEVILBOX_VERSION = 'v3.0.0-beta-0.2'; -$DEVILBOX_DATE = '2022-12-27'; +$DEVILBOX_VERSION = 'v3.0.0-beta-0.3'; +$DEVILBOX_DATE = '2023-01-02'; $DEVILBOX_API_PAGE = 'devilbox-api/status.json'; // diff --git a/.devilbox/www/htdocs/_ajax_callback.php b/.devilbox/www/htdocs/_ajax_callback.php index c7f9ef3b..d7c6b515 100644 --- a/.devilbox/www/htdocs/_ajax_callback.php +++ b/.devilbox/www/htdocs/_ajax_callback.php @@ -150,6 +150,11 @@ if (loadClass('Helper')->isLoggedIn()) { $_GET['software'] => (($version = loadClass('Php')->getWpcliVersion()) !== false) ? $version : $no )); } + else if ($_GET['software'] == 'wscat') { + echo json_encode(array( + $_GET['software'] => (($version = loadClass('Php')->getWscatVersion()) !== false) ? $version : $no + )); + } else if ($_GET['software'] == 'yarn') { echo json_encode(array( $_GET['software'] => (($version = loadClass('Php')->getYarnVersion()) !== false) ? $version : $no diff --git a/.devilbox/www/htdocs/cnc.php b/.devilbox/www/htdocs/cnc.php index 2a78c7cf..2456479b 100644 --- a/.devilbox/www/htdocs/cnc.php +++ b/.devilbox/www/htdocs/cnc.php @@ -65,7 +65,7 @@ function run_supervisor_command($command) { ); ?>
If you made a change to any vhost settings, you can trigger a manual reload here.
+If you made any changes to vhost settings (vhost-gen templates or backend configuration) or to the webserver configuration itself, you can trigger a manual reload of watcherd
here to apply them. No need to restart the Docker Compose stack.
Angular Cli | +Angular Cli | |||||||
---|---|---|---|---|---|---|---|---|
Wordpress Cli | ||||||||
Wscat | ++ | |||||||
Yarn | @@ -970,6 +974,7 @@ $HEALTH_PERCENT = 100 - ceil(100 * $HEALTH_FAILS / $HEALTH_TOTAL); updateVersions('vue_cli'); updateVersions('webpack_cli'); updateVersions('wpcli'); + updateVersions('wscat'); updateVersions('yarn'); })(); diff --git a/.devilbox/www/htdocs/info_vhostgen.php b/.devilbox/www/htdocs/info_vhostgen.php deleted file mode 100644 index c493652c..00000000 --- a/.devilbox/www/htdocs/info_vhostgen.php +++ /dev/null @@ -1,66 +0,0 @@ - -authPage(); ?> -redirect('/vhosts.php'); -} -if (!strlen($_GET['name'])) { - loadClass('Helper')->redirect('/vhosts.php'); -} -$vhost = $_GET['name']; -$found = false; -$vhosts = loadClass('Httpd')->getVirtualHosts(); -foreach ($vhosts as $v) { - if ($vhost == $v['name']) { - $found = true; - break; - } -} -// Be safe before using outputs -$vhost = htmlentities($vhost); - -?> - - - - getHead(true); ?> - - - - getNavbar(); ?> - - | docker-php-fpm-8.2 | PHP 8.2 base images (amd64 and arm64 ) |
|||||
docker-php-fpm-8.3 | +PHP 8.3 base images (amd64 and arm64 ) |
+ |||||||
docker-php-fpm | PHP-FPM Devilbox images (amd64 and arm64 ) |
diff --git a/.devilbox/www/htdocs/vhosts.php b/.devilbox/www/htdocs/vhosts.php
index 3a14913c..4b37386e 100644
--- a/.devilbox/www/htdocs/vhosts.php
+++ b/.devilbox/www/htdocs/vhosts.php
@@ -26,8 +26,8 @@
DocumentRoot | Backend | Config | -Valid | -URL | +Valid | +URL | getEnv('HOST_PATH_HTTPD_DATADIR');?>//getEnv('HTTPD_DOCROOT_DIR');?> | getVhostBackend($vHost['name']); ?> | - - getVhostgenTemplatePath($vHost['name'])) !== false): ?> - - - + + + + + + + + getVhostgenTemplatePath($vHost['name'])) !== false): ?> + + + + | -- | + | + | diff --git a/.devilbox/www/include/lib/container/Php.php b/.devilbox/www/include/lib/container/Php.php index ce78160c..349aad8a 100644 --- a/.devilbox/www/include/lib/container/Php.php +++ b/.devilbox/www/include/lib/container/Php.php @@ -140,6 +140,11 @@ class Php extends BaseClass implements BaseInterface $output = loadClass('Helper')->exec('wp --version 2>/dev/null | grep -i ^WP', $output); return loadClass('Helper')->egrep('/[0-9.]+/', $output); } + public function getWscatVersion() + { + $output = loadClass('Helper')->exec('wscat --version 2>/dev/null | head -1', $output); + return loadClass('Helper')->egrep('/[0-9.]+/', $output); + } public function getYarnVersion() { $output = loadClass('Helper')->exec('yarn --version 2>/dev/null', $output); diff --git a/.devilbox/www/include/vendor/Mail/mimeDecode.php b/.devilbox/www/include/vendor/Mail/mimeDecode.php index 4e2d5b6c..edb75bc8 100644 --- a/.devilbox/www/include/vendor/Mail/mimeDecode.php +++ b/.devilbox/www/include/vendor/Mail/mimeDecode.php @@ -28,8 +28,8 @@ * - Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * - Neither the name of the authors, nor the names of its contributors - * may be used to endorse or promote products derived from this + * - Neither the name of the authors, nor the names of its contributors + * may be used to endorse or promote products derived from this * software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" @@ -142,11 +142,11 @@ class Mail_mimeDecode extends PEAR /** * Flag to determine whether to decode headers * (set to UTF8 to iconv convert headers) - * @var mixed + * @var mixed * @access private */ var $_decode_headers; - + /** * Flag to determine whether to include attached messages @@ -182,7 +182,7 @@ class Mail_mimeDecode extends PEAR { $this->__construct($input); } - + /** * Begins the decoding process. If called statically @@ -197,7 +197,7 @@ class Mail_mimeDecode extends PEAR * of the parts. (Transfer encoding) * decode_headers - Whether to decode headers, * - use "UTF8//IGNORE" to convert charset. - * + * * input - If called statically, this will be treated * as the input * @return object Decoded results @@ -229,17 +229,17 @@ class Mail_mimeDecode extends PEAR $params['decode_headers'] : false; $this->_rfc822_bodies = isset($params['rfc_822bodies']) ? $params['rfc_822bodies'] : false; - + if (is_string($this->_decode_headers) && !function_exists('iconv')) { PEAR::raiseError('header decode conversion requested, however iconv is missing'); } - + $structure = $this->_decode($this->_header, $this->_body); if ($structure === false) { $structure = $this->raiseError($this->_error); } } - + return $structure; } @@ -320,10 +320,10 @@ class Mail_mimeDecode extends PEAR $encoding = isset($content_transfer_encoding) ? $content_transfer_encoding['value'] : '7bit'; $this->_include_bodies ? $return->body = ($this->_decode_bodies ? $this->_decodeBody($body, $encoding) : $body) : null; break; - + case 'multipart/signed': // PGP $parts = $this->_boundarySplit($body, $content_type['other']['boundary'], true); - $return->parts['msg_body'] = $parts[0]; + $return->parts['msg_body'] = $parts[0]; list($part_header, $part_body) = $this->_splitBodyHeader($parts[1]); $return->parts['sig_hdr'] = $part_header; $return->parts['sig_body'] = $part_body; @@ -404,7 +404,7 @@ class Mail_mimeDecode extends PEAR } for ($i = 0; $i < count($structure->parts); $i++) { - + if (!empty($structure->headers['content-type']) AND substr(strtolower($structure->headers['content-type']), 0, 8) == 'message/') { $prepend = $prepend . $mime_number . '.'; $_mime_number = ''; @@ -424,7 +424,7 @@ class Mail_mimeDecode extends PEAR $structure->mime_id = $prepend . $mime_number; $no_refs ? $return[$prepend . $mime_number] = '' : $return[$prepend . $mime_number] = &$structure; } - + return $return; } @@ -442,7 +442,7 @@ class Mail_mimeDecode extends PEAR if (preg_match("/^(.*?)\r?\n\r?\n(.*)/s", $input, $match)) { return array($match[1], $match[2]); } - // bug #17325 - empty bodies are allowed. - we just check that at least one line + // bug #17325 - empty bodies are allowed. - we just check that at least one line // of headers exist.. if (count(explode("\n",$input))) { return array($input, ''); @@ -466,11 +466,11 @@ class Mail_mimeDecode extends PEAR // Unfold the input $input = preg_replace("/\r?\n/", "\r\n", $input); //#7065 - wrapping.. with encoded stuff.. - probably not needed, - // wrapping space should only get removed if the trailing item on previous line is a + // wrapping space should only get removed if the trailing item on previous line is a // encoded character $input = preg_replace("/=\r\n(\t| )+/", '=', $input); $input = preg_replace("/\r\n(\t| )+/", ' ', $input); - + $headers = explode("\r\n", trim($input)); $got_start = false; foreach ($headers as $value) { @@ -485,7 +485,7 @@ class Mail_mimeDecode extends PEAR $got_start = true; } } - + $hdr_name = substr($value, 0, $pos = strpos($value, ':')); $hdr_value = substr($value, $pos+1); if($hdr_value[0] == ' ') { @@ -520,7 +520,7 @@ class Mail_mimeDecode extends PEAR * filename*0*=ENC'lang'urlencoded data. * filename*1*=ENC'lang'urlencoded data. * - * + * * * @param string Header value to parse * @return array Contains parsed result @@ -554,7 +554,7 @@ class Mail_mimeDecode extends PEAR $lq = ''; // last quote.. while ($i < $l) { - + $c = $input[$i]; //var_dump(array('i'=>$i,'c'=>$c,'q'=>$q, 'lq'=>$lq, 'key'=>$key, 'val' =>$val)); @@ -566,7 +566,7 @@ class Mail_mimeDecode extends PEAR } $escaped = true; $c = $input[$i]; - } + } // state - in key.. @@ -588,7 +588,7 @@ class Mail_mimeDecode extends PEAR $i++; continue; } - + // state - in value.. (as $val is set..) if ($q === false) { @@ -597,10 +597,10 @@ class Mail_mimeDecode extends PEAR $i++; continue; // skip leading spaces after '=' or after '"' } - - // do not de-quote 'xxx*= itesm.. + + // do not de-quote 'xxx*= itesm.. $key_is_trans = $key[strlen($key)-1] == '*'; - + if (!$key_is_trans && !$escaped && ($c == '"' || $c == "'")) { // start quoted area.. $q = $c; @@ -612,7 +612,7 @@ class Mail_mimeDecode extends PEAR } // got end.... if (!$escaped && $c == ';') { - + $return['other'][$key] = trim($val); $val = false; $key = ''; @@ -625,31 +625,31 @@ class Mail_mimeDecode extends PEAR $i++; continue; } - + // state - in quote.. if (!$escaped && $c == $q) { // potential exit state.. - + // end of quoted string.. $lq = $q; $q = false; $i++; continue; } - + // normal char inside of quoted string.. $val.= $c; $i++; } - + // do we have anything left.. if (strlen(trim($key)) || $val !== false) { - + $val = trim($val); - + $return['other'][$key] = $val; } - - + + $clean_others = array(); // merge added values. eg. *1[*] foreach($return['other'] as $key =>$val) { @@ -659,12 +659,12 @@ class Mail_mimeDecode extends PEAR $clean_others[$key] .= $val; continue; } - + } $clean_others[$key] = $val; - + } - + // handle language translation of '*' ending others. foreach( $clean_others as $key =>$val) { if ( $key[strlen($key)-1] != '*') { @@ -677,26 +677,26 @@ class Mail_mimeDecode extends PEAR // extended-other-values $match = array(); $info = preg_match("/^([^']+)'([^']*)'(.*)$/", $val, $match); - + $clean_others[$key] = urldecode($match[3]); $clean_others[strtolower($key)] = $clean_others[$key]; $clean_others[strtolower($key).'-charset'] = $match[1]; $clean_others[strtolower($key).'-language'] = $match[2]; - - + + } - - + + $return['other'] = $clean_others; - + // decode values. foreach($return['other'] as $key =>$val) { $charset = isset($return['other'][$key . '-charset']) ? $return['other'][$key . '-charset'] : false; - + $return['other'][$key] = $this->_decodeHeader($val, $charset); } - + return $return; } @@ -729,7 +729,7 @@ class Mail_mimeDecode extends PEAR $parts[] = $tmp[$i]; } } - + // add the last part on if it does not end with the 'closing indicator' if (!empty($tmp[$len]) && strlen(trim($tmp[$len])) && $tmp[$len][0] != '-') { $parts[] = $tmp[$len]; @@ -781,12 +781,12 @@ class Mail_mimeDecode extends PEAR } $input = str_replace($encoded, $text, $input); } - + if ($default_charset && is_string($this->_decode_headers)) { $conv = @iconv($charset, $this->_decode_headers, $input); $input = ($conv === false) ? $input : $conv; } - + return $input; } @@ -832,10 +832,12 @@ class Mail_mimeDecode extends PEAR // Remove soft line breaks $input = preg_replace("/=\r?\n/", '', $input); - // cytopia edit if (version_compare(PHP_VERSION, '7.2.0', '>=')) { $cb = function($matches) { - return chr(hexdec($matches[0])); + // cytopia edit (added ctype_xdigit() check around) + if (ctype_xdigit($matches[0])) { + return chr(hexdec($matches[0])); + } }; } else { // Replace encoded characters @@ -924,7 +926,7 @@ class Mail_mimeDecode extends PEAR /** * getSendArray() returns the arguments required for Mail::send() - * used to build the arguments for a mail::send() call + * used to build the arguments for a mail::send() call * * Usage: * $mailtext = Full email (for example generated by a template) @@ -966,7 +968,7 @@ class Mail_mimeDecode extends PEAR } $to = substr($to,1); return array($to,$header,$this->_body); - } + } /** * Returns a xml copy of the output of diff --git a/.tests/Makefile b/.tests/Makefile index 16d8e66e..98425be4 100644 --- a/.tests/Makefile +++ b/.tests/Makefile @@ -6,12 +6,24 @@ endif # ------------------------------------------------------------------------------------------------- # Misc Targets # ------------------------------------------------------------------------------------------------- -update-readme: +.PHONY: update-readme +update-readme: _update-readme-modules +update-readme: _update-readme-tools + +.PHONY: _update-readme-modules +_update-readme-modules: cat "../README.md" \ | perl -0 -pe "s#.*#\n$$(./scripts/get-modules.sh)\n#s" \ > "../README.md.tmp" yes | mv -f "../README.md.tmp" "../README.md" +.PHONY: _update-readme-tools +_update-readme-tools: + cat "../README.md" \ + | perl -0 -pe "s#.*#\n$$(./scripts/get-tools.sh)\n#s" \ + > "../README.md.tmp" + yes | mv -f "../README.md.tmp" "../README.md" + # ------------------------------------------------------------------------------------------------- # Linting Targets diff --git a/.tests/scripts/get-modules.sh b/.tests/scripts/get-modules.sh index 663c1d0b..4383f22a 100755 --- a/.tests/scripts/get-modules.sh +++ b/.tests/scripts/get-modules.sh @@ -94,7 +94,7 @@ MODS="$( echo "${PHP52_MODS}, ${PHP53_MODS}, ${PHP54_MODS}, ${PHP55_MODS}, ${PHP ### ### Get disabled modules ### -DISABLED=",blackfire,ioncube,phalcon,psr,$( grep -E '^PHP_MODULES_DISABLE=' "${DVLBOX_PATH}/env-example" | sed 's/.*=//g' )," +DISABLED=",blackfire,ioncube,phalcon,psr,xhprof,$( grep -E '^PHP_MODULES_DISABLE=' "${DVLBOX_PATH}/env-example" | sed 's/.*=//g' )," #echo $DISABLED B="โ" # Enabled base modules (cannot be disabled) E="๐ธ" # Enabled mods modules (can be disabled) diff --git a/.tests/scripts/get-tools.sh b/.tests/scripts/get-tools.sh new file mode 100755 index 00000000..3c53bf41 --- /dev/null +++ b/.tests/scripts/get-tools.sh @@ -0,0 +1,25 @@ +#!/usr/bin/env bash + +# NOTE: Parsing curl to tac to circumnvent "failed writing body" +# https://stackoverflow.com/questions/16703647/why-curl-return-and-error-23-failed-writing-body + +set -e +set -u +set -o pipefail + +SCRIPT_PATH="$( cd "$(dirname "$0")" && pwd -P )" +DVLBOX_PATH="$( cd "${SCRIPT_PATH}/../.." && pwd -P )" +# shellcheck disable=SC1090 +. "${SCRIPT_PATH}/.lib.sh" + +RETRIES=10 + + +# ------------------------------------------------------------------------------------------------- +# FUNCTIONS +# ------------------------------------------------------------------------------------------------- + +PHP_TAG="$( grep 'devilbox/php' "${DVLBOX_PATH}/docker-compose.yml" | sed 's/^.*-work-//g' )" +PHP_TOOLS="$( run "curl -sS 'https://raw.githubusercontent.com/devilbox/docker-php-fpm/${PHP_TAG}/doc/available-tools.md'" "${RETRIES}" )"; + +echo "${PHP_TOOLS}" | grep -A 1000000 'TOOLS_WORK_START' diff --git a/.tests/tests/intranet-vhost.sh b/.tests/tests/intranet-vhost.sh index 41b15fc8..66c52054 100755 --- a/.tests/tests/intranet-vhost.sh +++ b/.tests/tests/intranet-vhost.sh @@ -54,7 +54,7 @@ fi HOST_PORT_HTTPD="$( "${SCRIPT_PATH}/../scripts/env-getvar.sh" "HOST_PORT_HTTPD" )" TLD_SUFFIX="$( "${SCRIPT_PATH}/../scripts/env-getvar.sh" "TLD_SUFFIX" )" HTTPD_DOCROOT_DIR="$( "${SCRIPT_PATH}/../scripts/env-getvar.sh" "HTTPD_DOCROOT_DIR" )" -HTTPD_TEMPLATE_DIR="$( "${SCRIPT_PATH}/../scripts/env-getvar.sh" "HTTPD_TEMPLATE_DIR" )" +#HTTPD_TEMPLATE_DIR="$( "${SCRIPT_PATH}/../scripts/env-getvar.sh" "HTTPD_TEMPLATE_DIR" )" ### @@ -128,14 +128,14 @@ fi ### ### Vhost config link is available ### -printf "[TEST] vhost.d config link is available" -if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep 'vhost.d/${VHOST}.conf' >/dev/null" "${RETRIES}" "" "0"; then - printf "\\r[FAIL] vhost.d config link is available\\n" - run "curl 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' || true" - exit 1 -else - printf "\\r[OK] vhost.d config link is available\\n" -fi +#printf "[TEST] vhost.d config link is available" +#if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep 'vhost.d/${VHOST}.conf' >/dev/null" "${RETRIES}" "" "0"; then +# printf "\\r[FAIL] vhost.d config link is available\\n" +# run "curl 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' || true" +# exit 1 +#else +# printf "\\r[OK] vhost.d config link is available\\n" +#fi ### @@ -154,62 +154,62 @@ fi ### ### vhost-gen config link should appear ### -run "docker-compose exec --user devilbox -T php mkdir -p /shared/httpd/${VHOST}/${HTTPD_TEMPLATE_DIR}" "${RETRIES}" "${DVLBOX_PATH}" -run "cp ${DVLBOX_PATH}/cfg/vhost-gen/apache22.yml-example-vhost ${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache22.yml" "${RETRIES}" -run "cp ${DVLBOX_PATH}/cfg/vhost-gen/apache24.yml-example-vhost ${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache24.yml" "${RETRIES}" -run "cp ${DVLBOX_PATH}/cfg/vhost-gen/nginx.yml-example-vhost ${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/nginx.yml" "${RETRIES}" - -printf "[TEST] vhost-gen config link is available" -if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep 'info_vhostgen.php?name=${VHOST}' >/dev/null" "${RETRIES}" "" "0"; then - printf "\\r[FAIL] vhost-gen config link is available\\n" - run "curl 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' || true" - exit 1 -else - printf "\\r[OK] vhost-gen config link is available\\n" -fi +#run "docker-compose exec --user devilbox -T php mkdir -p /shared/httpd/${VHOST}/${HTTPD_TEMPLATE_DIR}" "${RETRIES}" "${DVLBOX_PATH}" +#run "cp ${DVLBOX_PATH}/cfg/vhost-gen/apache22.yml-example-vhost ${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache22.yml" "${RETRIES}" +#run "cp ${DVLBOX_PATH}/cfg/vhost-gen/apache24.yml-example-vhost ${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache24.yml" "${RETRIES}" +#run "cp ${DVLBOX_PATH}/cfg/vhost-gen/nginx.yml-example-vhost ${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/nginx.yml" "${RETRIES}" +# +#printf "[TEST] vhost-gen config link is available" +#if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep 'info_vhostgen.php?name=${VHOST}' >/dev/null" "${RETRIES}" "" "0"; then +# printf "\\r[FAIL] vhost-gen config link is available\\n" +# run "curl 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' || true" +# exit 1 +#else +# printf "\\r[OK] vhost-gen config link is available\\n" +#fi ### ### vhost-gen config should be available ### -printf "[TEST] vhost-gen config is available" -if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' | tac | tac | grep '__VHOST_NAME__' >/dev/null" "${RETRIES}" "" "0"; then - printf "\\r[FAIL] vhost-gen config is available\\n" - run "curl 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' || true" - exit 1 -else - printf "\\r[OK] vhost-gen config is available\\n" -fi +#printf "[TEST] vhost-gen config is available" +#if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' | tac | tac | grep '__VHOST_NAME__' >/dev/null" "${RETRIES}" "" "0"; then +# printf "\\r[FAIL] vhost-gen config is available\\n" +# run "curl 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' || true" +# exit 1 +#else +# printf "\\r[OK] vhost-gen config is available\\n" +#fi ### ### vhost-gen config changes are shown in intranet ### -replace "__INDEX__" "__MY_GREP_VALUE__" "${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache22.yml" -replace "__INDEX__" "__MY_GREP_VALUE__" "${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache24.yml" -replace "__INDEX__" "__MY_GREP_VALUE__" "${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/nginx.yml" - -printf "[TEST] vhost-gen config changes are shown" -if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' | tac | tac | grep '__MY_GREP_VALUE__' >/dev/null" "${RETRIES}" "" "0"; then - printf "\\r[FAIL] vhost-gen config changes are shown\\n" - run "curl 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' || true" - exit 1 -else - printf "\\r[OK] vhost-gen config changes are shown\\n" -fi +#replace "__INDEX__" "__MY_GREP_VALUE__" "${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache22.yml" +#replace "__INDEX__" "__MY_GREP_VALUE__" "${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/apache24.yml" +#replace "__INDEX__" "__MY_GREP_VALUE__" "${SCRIPT_PATH}/../www/${VHOST}/${HTTPD_TEMPLATE_DIR}/nginx.yml" +# +#printf "[TEST] vhost-gen config changes are shown" +#if ! run "curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' | tac | tac | grep '__MY_GREP_VALUE__' >/dev/null" "${RETRIES}" "" "0"; then +# printf "\\r[FAIL] vhost-gen config changes are shown\\n" +# run "curl 'http://localhost:${HOST_PORT_HTTPD}/info_vhostgen.php?name=${VHOST}' || true" +# exit 1 +#else +# printf "\\r[OK] vhost-gen config changes are shown\\n" +#fi ### ### Vhost disappears after removing its dir ### -run "docker-compose exec --user devilbox -T php rm -rf /shared/httpd/${VHOST}" "${RETRIES}" "${DVLBOX_PATH}" -run "sleep 4" - -printf "[TEST] vhost disappears after removing its dir" -if ! run "test \"\$(curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep -c '${VHOST}')\" = \"0\"" "${RETRIES}" "" "0"; then - printf "\\r[FAIL] vhost disappears after removing its dir\\n" - run "curl 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep '${VHOST}' || true" - exit 1 -else - printf "\\r[OK] vhost disappears after removing its dir\\n" -fi +#run "docker-compose exec --user devilbox -T php rm -rf /shared/httpd/${VHOST}" "${RETRIES}" "${DVLBOX_PATH}" +#run "sleep 4" +# +#printf "[TEST] vhost disappears after removing its dir" +#if ! run "test \"\$(curl -sS --fail 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep -c '${VHOST}')\" = \"0\"" "${RETRIES}" "" "0"; then +# printf "\\r[FAIL] vhost disappears after removing its dir\\n" +# run "curl 'http://localhost:${HOST_PORT_HTTPD}/vhosts.php' | tac | tac | grep '${VHOST}' || true" +# exit 1 +#else +# printf "\\r[OK] vhost disappears after removing its dir\\n" +#fi diff --git a/CHANGELOG.md b/CHANGELOG.md index 212b40ab..4d9d8de8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,24 @@ Make sure to have a look at [UPDATING.md](https://github.com/cytopia/devilbox/bl ## Unreleased +## Release v3.0.0-beta-0.3 (2022-01-02) + +This release provides the `dvl.to` domain to be used with `TLD_SUFFIX` (set to default), which eliminates the need to set any entries in `/etc/hosts`, as all of its subdomain will point to `127.0.0.1` via official DNS. Domain has been acquired thanks to awesome sponsors! + +### Fixed +- Intranet: mail.php fixed deprecation warnings [#798](https://github.com/cytopia/devilbox/issues/798) +- Added `host.docker.internal` to extra_hosts to be able to connect to the host system [#919](https://github.com/cytopia/devilbox/issues/919) + +### Changed +- Use `dvl.to` as default `TLD_SUFFIX` (it always poits to `127.0.0.1` removing the need to create `/etc/hosts` entries) + +### Added +- Intranet: vhost overview shows listening ports +- Intranet: vhost overview now has modals to show httpd and vhost-gen configs +- Docs: Show available tools per version in README.md +- Added `xhprof` PHP extension + + ## Release v3.0.0-beta-0.2 (2022-12-27) The Backend configuration now supports websockets as well: @@ -40,6 +58,7 @@ Once you're done with `backend.cfg` changes, head over to the Intranet C&C page ### Added - Reverse Proxy automation for websocket projects (`ws:// |
+ Automation + :star: Automated Project creation + :star: Automated SSL + :star: Automated DNS + :star: Host permission sync + |
+
+ Modes + :star: Static files + :star: PHP files + :star: Reverse Proxy + :star: Websockets + |
+
+ Backends + :star: PHP-FPM + :star: NodeJS + :star: Python + :star: Golang + :star: ... + |
+
+ Profiling + :star: Blackfire + :star: Xdebug + :star: XHProf + |
+
+ Projects + :star: Unlimited Projects + :star: Inter-Project Communication + :star: Custom Project domains + :star: Valid browser HTTPS + |
+
+ Intranet + :star: Virtual Hosts + :star: C&C + :star: Email Reader + :star: OpCache Gui + |
+
+ Batteries + :star: Adminer + :star: phpMyAdmin + :star: phpPgAdmin + :star: phpRedMind + |
+
+ Services + :star: SQL + :star: NoSQL + :star: Cache + :star: ... + |
+
๐ Docs |
- ๐ฎ Discord |
- ๐ช Forum |
- ๐ฅ Flames |
-
---|---|---|---|
-
- ![]() |
-
-
- ![]() |
-
-
- ![]() |
-
-
- ![]() |
-
devilbox.readthedocs.io | -discord/devilbox | -devilbox.discourse.group | -github.com/devilbox/flames | -
Linux and MacOS | -Windows | -
---|---|
-# Get the Devilbox
-git clone https://github.com/cytopia/devilbox # Create docker-compose environment file
-cd devilbox
-cp env-example .env # Edit your configuration
-vim .env # Start all container
-docker-compose up |
-
- 1. Clone https://github.com/cytopia/devilbox to C:\devilbox with Git for Windows- 2. Copy C:\devilbox\env-example to C:\devilbox\.env - 3. Edit C:\devilbox\.env - 4. Open a terminal on Windows and type: - # Start all container -C:\devilbox> docker-compose up- |
-
Linux and MacOS | -Windows | -
---|---|
-host> ./shell.sh
-devilbox@php-7.0.19 in /shared/httpd $ |
-
-C:\devilbox> shell.bat
-devilbox@php-7.0.19 in /shared/httpd $ |
-
:star: HTTPS support | -HTTPS is available by default for all projects and the bundled Intranet. | -
:star: HTTP/2 support | -All HTTPS connections will offer HTTP/2 as the default protocol, except for Apache 2.2 which does not support it. | -
:star: Auto virtual hosts | -New virtual hosts are created automatically and instantly whenever you add a project directory. This is done internally via vhost-gen and watcherd. | -
:star: Automated SSL certs | -Valid SSL certificates for HTTPS are automatically created for each vhost and signed by the Devilbox CA. | -
:star: Unlimited vhosts | -Run as many projects as you need with a single instance of the Devilbox. | -
:star: Custom vhosts | -You can overwrite and customise the default applied vhost configuration for every single vhost. | -
:star: Reverse proxy | -Have your NodeJS application served with a nice domain name and valid HTTPS. | -
:star: Custom domains | -Choose whatever development domain you desire: *.loc , *.dev or use real domains as well: *.example.com |
-
:star: Auto DNS | -An integrated BIND server is able to create DNS entries automatically for your chosen domains. | -
:star: Auto start scripts | -Custom startup scripts can be provided for all PHP container equally and also differently per PHP version to install custom software or automatically startup up your required tools. | -
:star: Custom PHP config | -Overwrite any setting for PHP. | -
:star: Email catch-all | -All outgoing emails are catched and will be presented in the included intranet. | -
:star: Self-validation | -Projects and configuration options are validated and marked in the intranet. | -
:star: Xdebug | -Xdebug and a full blown PHP-FPM server is ready to serve. | -
:star: Devilbox Flames | -Devilbox community plugins a.k.a. Devilbox Flames. | -
:star: Many more | -See Documentation for all available features. | -
![]() |
- ![]() |
- ![]() |
- ![]() |
- ![]() |
- ![]() |
- ![]() |
-
Adminer | -phpMyAdmin | -phpPgAdmin | -phpRedMin | -PHP Memcached Admin | -OpCache GUI | -Mail viewer | -
:wrench: awesome-ci | -A set of tools for static code analysis:file-cr , file-crlf , file-empty , file-nullbyte-char , file-trailing-newline , file-trailing-single-newline , file-trailing-space , file-utf8 , file-utf8-bom , git-conflicts , git-ignored , inline-css , inline-js , regex-grep , regex-perl , syntax-bash , syntax-css , syntax-js , syntax-json , syntax-markdown , syntax-perl , syntax-php , syntax-python , syntax-ruby , syntax-scss , syntax-sh |
-
:wrench: git flow | -git-flow is a Git extensions to provide high-level repository operations for Vincent Driessen's branching model. |
-
:wrench: json lint | -jsonlint is a command line linter for JSON files. |
-
:wrench: laravel installer | -laravel is a command line tool that lets you easily install the Laravel framework. |
-
: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: markdownlint | -markdownlint is a markdown linter. |
-
:wrench: mdl | -mdl is a markdown linter. |
-
:wrench: phalcon devtools | -phalcon is a command line tool that lets you easily install the PhalconPHP framework. |
-
:wrench: photon installer | -photon is a command line tool that lets you easily install the PhotonCMS. |
-
:wrench: php code sniffer | -phpcs is a command line tool that tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards. |
-
:wrench: php code beautifier | -phpcbf is a command line tool that automatically correct coding standard violations. |
-
:wrench: php cs fixer | -php-cs-fixer is a tool to automatically fix PHP Coding Standards issues. |
-
:wrench: pm2 | -pm2 is Node.js Production Process Manager with a built-in Load Balancer. |
-
:wrench: stylelint | -stylelint is a css/scss linter. |
-
:wrench: symfony installer | -symfony is a command line tool that lets you easily install the Symfony framework. |
-
:wrench: tig | -tig is a text-mode interface for git. |
-
:wrench: wp-cli | -wp is a command line tool that lets you easily install WordPress. |
-
:wrench: yamllint | -yamllint is a linter for yaml files. |
-
![]() |
+ ![]() |
+ ![]() |
+ ![]() |
+ ![]() |
+ ![]() |
+ ![]() |
+
Adminer | +phpMyAdmin | +phpPgAdmin | +phpRedMin | +PHP Memcached Admin | +OpCache GUI | +Mail viewer | +
๐ Docs |
+ ๐ฎ Discord |
+ ๐ช Forum |
+ ๐ฅ Flames |
+
---|---|---|---|
+
+ ![]() |
+
+
+ ![]() |
+
+
+ ![]() |
+
+
+ ![]() |
+
devilbox.readthedocs.io | +discord/devilbox | +devilbox.discourse.group | +github.com/devilbox/flames | +