From 6aa25e52c4c444a9148b4817ce1b3c09d6a21620 Mon Sep 17 00:00:00 2001 From: Richard Davies Date: Thu, 10 Dec 2020 09:05:12 -0800 Subject: [PATCH 001/258] Update lando-with-vscode.md Updated config with Xdebug 3 changes and added advanced setup section with custom tooling to toggle xdebug on and off. --- docs/guides/lando-with-vscode.md | 61 +++++++++++++++++++++++++++++--- 1 file changed, 56 insertions(+), 5 deletions(-) diff --git a/docs/guides/lando-with-vscode.md b/docs/guides/lando-with-vscode.md index 553769a87..45ab26ef3 100644 --- a/docs/guides/lando-with-vscode.md +++ b/docs/guides/lando-with-vscode.md @@ -65,9 +65,10 @@ xdebug.max_nesting_level = 256 xdebug.show_exception_trace = 0 xdebug.collect_params = 0 ; Extra custom Xdebug setting for debug to work in VSCode. -xdebug.remote_enable = 1 -xdebug.remote_autostart = 1 -xdebug.remote_host = ${LANDO_HOST_IP} +xdebug.mode = debug +xdebug.client_host = ${LANDO_HOST_IP} +xdebug.remote_port = 9003 +xdebug.start_with_request = trigger ; xdebug.remote_connect_back = 1 xdebug.remote_log = /tmp/xdebug.log ``` @@ -93,7 +94,7 @@ code .vscode/launch.json "name": "Listen for XDebug", "type": "php", "request": "launch", - "port": 9000, + "port": 9003, "log": false, "pathMappings": { "/app/": "${workspaceFolder}/", @@ -107,6 +108,56 @@ Done! You can now click start debugging (type F5 or click on the icon in the left sidebar). +## Advanced Setup + +Optionally for better performance you can easily toggle Xdebug on and off with some custom tooling commands. + +If you're using Apache, add this to your `.lando.yml`: + +```yaml +tooling: + xdebug-on: + service: appserver + description: Enable xdebug for Apache. + cmd: docker-php-ext-enable xdebug && /etc/init.d/apache2 reload && echo "Enabling xdebug" + user: root + + xdebug-off: + service: appserver + description: Disable xdebug for Apache. + cmd: rm /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini && /etc/init.d/apache2 reload && echo "Disabling xdebug" + user: root +``` + +If you're using Nginx, add this to your `.lando.yml`: + +```yaml +tooling: + xdebug-on: + service: appserver + description: Enable xdebug for nginx. + cmd: docker-php-ext-enable xdebug && pkill -o -USR2 php-fpm && echo "Enabling xdebug" + user: root + xdebug-off: + service: appserver + description: CUSTOM Disable xdebug for nginx. + cmd: rm /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini && pkill -o -USR2 php-fpm && echo "Disabling xdebug" + user: root +``` + +Now you can turn Xdebug on or off with `lando xdebug-on` and `lando xdebug-off`. If you want Xdebug off by default, set `xdebug:false` in your appserver config: + +```yaml +name: mywebsite +recipe: drupal8 +services: + appserver: + webroot: web + xdebug: false + config: + php: .vscode/php.ini +``` + ## Debugging PhpUnit Debugging PhpUnit tests in VSCode requires a little more setup, but Lando helps to make it easier. @@ -121,7 +172,7 @@ First, you need to have VSCode listen for debugging on 2 separate ports, because "name": "Listen for XDebug", "type": "php", "request": "launch", - "port": 9000, + "port": 9003, "log": true, "pathMappings": { "/app/": "${workspaceFolder}/", From c46c56a2477fc82065a191a68c82c370a0ec0e27 Mon Sep 17 00:00:00 2001 From: Richard Davies Date: Fri, 11 Dec 2020 14:30:49 -0800 Subject: [PATCH 002/258] Update lando-with-vscode.md Update instructions for xdebug 3 (with appropriate callouts for users still using xdebug 2). --- docs/guides/lando-with-vscode.md | 34 +++++++++++++++++++++++++++----- 1 file changed, 29 insertions(+), 5 deletions(-) diff --git a/docs/guides/lando-with-vscode.md b/docs/guides/lando-with-vscode.md index 45ab26ef3..14adacd29 100644 --- a/docs/guides/lando-with-vscode.md +++ b/docs/guides/lando-with-vscode.md @@ -55,7 +55,9 @@ The location of this file is arbitrary. We placed it inside `.vscode/` folder simply because we find it convenient. -Add your custom XDebug settings. +Add your custom XDebug settings, which will vary slightly depending on which version of PHP and xdebug you're using. + +**PHP 7.2+ uses xdebug 3** and needs `config:` under `services:` as follow: ```ini [PHP] @@ -70,6 +72,23 @@ xdebug.client_host = ${LANDO_HOST_IP} xdebug.remote_port = 9003 xdebug.start_with_request = trigger ; xdebug.remote_connect_back = 1 +xdebug.log = /tmp/xdebug.log +``` + +**PHP 7.1 and earlier uses xdebug 2** and needs `config:` under `services:` as follow: + +```ini +[PHP] + +; Xdebug +xdebug.max_nesting_level = 256 +xdebug.show_exception_trace = 0 +xdebug.collect_params = 0 +; Extra custom Xdebug setting for debug to work in VSCode. +xdebug.remote_enable = 1 +xdebug.remote_autostart = 1 +xdebug.remote_host = ${LANDO_HOST_IP} +; xdebug.remote_connect_back = 1 xdebug.remote_log = /tmp/xdebug.log ``` @@ -104,6 +123,9 @@ code .vscode/launch.json } ``` +**Note: PHP 7.1 and earlier uses xdebug 2** which uses port 9000, so change the port number above accordinly. + + Done! You can now click start debugging (type F5 or click on the icon in the left sidebar). @@ -200,9 +222,11 @@ Next add some custom tooling to your .lando.yml file, that provides a command to tooling: phpunitdebug: service: appserver - cmd: php -d xdebug.remote_port=9000 vendor/bin/phpunit + cmd: php -d xdebug.remote_port=9003 vendor/bin/phpunit ``` +**Note: PHP 7.1 and earlier uses xdebug 2** which uses port 9000, so change the port number above accordinly. + Now to run debug a PhpUnit test, do the following: 1. Select the compound "PhpUnit" as your debugger in VSCode's UI, and start it. @@ -226,13 +250,13 @@ tail -f /tmp/xdebug.log # Open your browser and refresh the app ``` -**Xdebug says "timeout trying to connect to XX.XX.XX:9000** +**Xdebug says "timeout trying to connect to XX.XX.XX:9003** -Double-check your host machine allow connection on its port 9000. +Double-check your host machine allow connection on its port 9003. This is how you can open a specific port on a Debian/Ubuntu: -`sudo iptables -A INPUT -p tcp -d 0/0 -s 0/0 --dport 9000 -j ACCEPT` +`sudo iptables -A INPUT -p tcp -d 0/0 -s 0/0 --dport 9003 -j ACCEPT` ## Read More From 470624c04dbcc52e35a34f284990cb13957fdfb5 Mon Sep 17 00:00:00 2001 From: Fran Garcia-Linares Date: Mon, 14 Dec 2020 21:19:26 +0100 Subject: [PATCH 003/258] Fix typo --- docs/config/lagoon.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/config/lagoon.md b/docs/config/lagoon.md index bbcdbf947..75b99b21a 100644 --- a/docs/config/lagoon.md +++ b/docs/config/lagoon.md @@ -226,7 +226,7 @@ lando pull --database none --files none ``` ```bash -lando pull +lando push Push db and files to Lagoon From 113b623016851d75cff5e9790829ff1b70d63a7c Mon Sep 17 00:00:00 2001 From: Richard Davies Date: Wed, 16 Dec 2020 08:11:38 -0800 Subject: [PATCH 004/258] Update lando-with-vscode.md remote_port changed to client_port in v3. Also allow xdebug.mode to be altered via suggestion in https://github.com/lando/lando/issues/2728 --- docs/guides/lando-with-vscode.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/guides/lando-with-vscode.md b/docs/guides/lando-with-vscode.md index 14adacd29..34f6f4a5f 100644 --- a/docs/guides/lando-with-vscode.md +++ b/docs/guides/lando-with-vscode.md @@ -69,7 +69,7 @@ xdebug.collect_params = 0 ; Extra custom Xdebug setting for debug to work in VSCode. xdebug.mode = debug xdebug.client_host = ${LANDO_HOST_IP} -xdebug.remote_port = 9003 +xdebug.client_port = 9003 xdebug.start_with_request = trigger ; xdebug.remote_connect_back = 1 xdebug.log = /tmp/xdebug.log @@ -137,6 +137,11 @@ Optionally for better performance you can easily toggle Xdebug on and off with s If you're using Apache, add this to your `.lando.yml`: ```yaml +services: + appserver: + overrides: + environment: + XDEBUG_MODE: tooling: xdebug-on: service: appserver @@ -154,6 +159,11 @@ tooling: If you're using Nginx, add this to your `.lando.yml`: ```yaml +services: + appserver: + overrides: + environment: + XDEBUG_MODE: tooling: xdebug-on: service: appserver From 3b5fa674fc8558b8bc412f61cb03f1642abe3fb2 Mon Sep 17 00:00:00 2001 From: owenbush Date: Sat, 19 Dec 2020 15:31:36 -0700 Subject: [PATCH 005/258] 2762 - Lagoon Pull - Fix hardcoded public file paths and minor bugs --- .../lando-lagoon/scripts/lagoon-pull.sh | 51 ++++++++++++++----- 1 file changed, 37 insertions(+), 14 deletions(-) diff --git a/integrations/lando-lagoon/scripts/lagoon-pull.sh b/integrations/lando-lagoon/scripts/lagoon-pull.sh index 8bbf25978..679a3febf 100755 --- a/integrations/lando-lagoon/scripts/lagoon-pull.sh +++ b/integrations/lando-lagoon/scripts/lagoon-pull.sh @@ -27,6 +27,9 @@ LANDO_SSH_KEY= LANDO_DB_ALIAS="none" LANDO_FILES_ALIAS="none" +# Set drupal paths +DRUPAL_FILES_PATH="web/sites/default/files" + # Auth options AUTH_HOST="ssh.lagoon.amazeeio.cloud" AUTH_USER="lagoon" @@ -96,8 +99,11 @@ done # Dynamically prefix alias if project name was not included if [[ "${LANDO_DB_ALIAS}" != "${LANDO_LAGOON_PROJECT}"* ]]; then LANDO_DB_ALIAS="${LANDO_LAGOON_PROJECT}-${LANDO_DB_ALIAS}" +fi +if [[ "${LANDO_FILES_ALIAS}" != "${LANDO_LAGOON_PROJECT}"* ]]; then LANDO_FILES_ALIAS="${LANDO_LAGOON_PROJECT}-${LANDO_FILES_ALIAS}" fi + # Prefix aliases with lagoon. LANDO_DB_ALIAS="lagoon.${LANDO_DB_ALIAS}" LANDO_FILES_ALIAS="lagoon.${LANDO_FILES_ALIAS}" @@ -119,15 +125,20 @@ drush la 1>/dev/null # Sync database if [ "${LANDO_DB_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then # Validate environment exists - lando_pink "Validating ${LANDO_DB_ALIAS} exists and you have access to it..." - if ! drush la | grep ${LANDO_DB_ALIAS}; then - lando_red "$LANDO_DB_ALIAS does not appear to be a valid environment!" + lando_pink "Validating database alias @${LANDO_DB_ALIAS} exists and you have access to it..." + if ! drush la | grep -q ${LANDO_DB_ALIAS}; then + lando_red "@$LANDO_DB_ALIAS does not appear to be a valid environment!" exit 1 fi + # Validate we can ping the remote environment - drush "@${LANDO_DB_ALIAS}" status -y - lando_green "Confirmed!" + if ! drush "@${LANDO_DB_ALIAS}" status -y >/dev/null; then + lando_red "Database alias @${LANDO_DB_ALIAS} access failed!" + exit 1 + fi + + lando_green "Database alias @$LANDO_DB_ALIAS access confirmed!" # Suppress drush messaging by assigning output echo "Destroying all current tables in database if needed... " @@ -137,27 +148,39 @@ if [ "${LANDO_DB_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then echo "Pulling your database... This miiiiight take a minute" LANDO_SSH_KEY=${LANDO_SSH_KEY} drush "@${LANDO_DB_ALIAS}" sql:dump -y | drush sql:cli -y else - echo "Skipping database" + lando_green "Skipping database" fi # Sync files if [ "${LANDO_FILES_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then # Validate environment exists - lando_pink "Validating ${LANDO_FILES_ALIAS} exists and you have access to it..." - if ! drush la | grep ${LANDO_FILES_ALIAS}; then - lando_red "$LANDO_FILES_ALIAS does not appear to be a valid environment!" + lando_pink "Validating file alias @${LANDO_FILES_ALIAS} exists and you have access to it..." + if ! drush la | grep -q ${LANDO_FILES_ALIAS}; then + lando_red "@$LANDO_FILES_ALIAS does not appear to be a valid environment!" exit 1 fi # Validate we can ping the remote environment - drush "@${LANDO_FILES_ALIAS}" status -y - lando_green "Confirmed!" + if ! drush "@${LANDO_FILES_ALIAS}" status -y >/dev/null; then + lando_red "Files alias @${LANDO_FILES_ALIAS} access failed!" + exit 1 + fi + + lando_green "Files alias @${LANDO_FILES_ALIAS} access confirmed!" + + if ! drush "@${LANDO_FILES_ALIAS}" status | grep -q "File directory path"; then + lando_red "Unable to pull files from $LANDO_FILES_ALIAS without a file directory path specified. Set up or import a database first." + exit 1 + else + DRUPAL_FILES_PATH=$(drush @${LANDO_FILES_ALIAS} dd files | tr -d '\n' 2>/dev/null) + fi + + lando_pink "Attemping to sync files to/from directory: $DRUPAL_FILES_PATH" # Import files with rsync - echo "Pulling files..." - LANDO_SSH_KEY=${LANDO_SSH_KEY} drush rsync @${LANDO_FILES_ALIAS}:web/sites/default/files web/sites/default -y + LANDO_SSH_KEY=${LANDO_SSH_KEY} drush rsync "@${LANDO_FILES_ALIAS}":${DRUPAL_FILES_PATH} ${DRUPAL_FILES_PATH} -y else - echo "Skipping files" + lando_green "Skipping files" fi # Finish up! From 1e0263b5e6eab5babeca4cff5068796e483a4320 Mon Sep 17 00:00:00 2001 From: Brian Adams Date: Mon, 21 Dec 2020 23:33:15 -0500 Subject: [PATCH 006/258] Allow setting node service port to false. --- plugins/lando-services/services/node/builder.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/lando-services/services/node/builder.js b/plugins/lando-services/services/node/builder.js index 9b048c30e..2d6a0ab38 100644 --- a/plugins/lando-services/services/node/builder.js +++ b/plugins/lando-services/services/node/builder.js @@ -97,7 +97,7 @@ module.exports = { LANDO_WEBROOT_UID: '1000', LANDO_WEBROOT_GID: '1000', }, - ports: (options.command !== 'tail -f /dev/null') ? [options.port] : [], + ports: (options.command !== 'tail -f /dev/null' && options.port !== false) ? [options.port] : [], volumes: options.volumes, command: `/bin/sh -c "${options.command}"`, }; From 38873996a037c10e1eb4701ae70911f50b135416 Mon Sep 17 00:00:00 2001 From: Brian Adams Date: Tue, 22 Dec 2020 00:38:00 -0500 Subject: [PATCH 007/258] Add docs for node port disabling. --- docs/config/node.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/config/node.md b/docs/config/node.md index f957ec9f8..26d673069 100644 --- a/docs/config/node.md +++ b/docs/config/node.md @@ -78,7 +78,7 @@ services: ### Setting a port -While we assume your `node` service is running on port `80`, we recognize that many `node` app's also run on port `3000` or otherwise. You can easily change our default to match whatever your app needs. +While we assume your `node` service is running on port `80`, we recognize that many `node` app's also run on port `3000` or otherwise. You can easily change our default to match whatever your app needs. If your `node` service doesn't require an exposed port, you can also set `port` to `false` to disable the default port `80` mapping. Note that if you set either `port` or `ssl` to a value less than `1024` then Lando will run the `command` as `root` otherwise it will run as the `node` user which for all intents and purposes is `you`. From 88e14718fd325927aae89448cfd4621faeaeded7 Mon Sep 17 00:00:00 2001 From: owenbush Date: Mon, 28 Dec 2020 08:48:28 -0700 Subject: [PATCH 008/258] Cleanup variable references in lando-pull.sh --- integrations/lando-lagoon/scripts/lagoon-pull.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/integrations/lando-lagoon/scripts/lagoon-pull.sh b/integrations/lando-lagoon/scripts/lagoon-pull.sh index 679a3febf..44655c795 100755 --- a/integrations/lando-lagoon/scripts/lagoon-pull.sh +++ b/integrations/lando-lagoon/scripts/lagoon-pull.sh @@ -127,7 +127,7 @@ if [ "${LANDO_DB_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then # Validate environment exists lando_pink "Validating database alias @${LANDO_DB_ALIAS} exists and you have access to it..." if ! drush la | grep -q ${LANDO_DB_ALIAS}; then - lando_red "@$LANDO_DB_ALIAS does not appear to be a valid environment!" + lando_red "@${LANDO_DB_ALIAS} does not appear to be a valid environment!" exit 1 fi @@ -138,7 +138,7 @@ if [ "${LANDO_DB_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then exit 1 fi - lando_green "Database alias @$LANDO_DB_ALIAS access confirmed!" + lando_green "Database alias @${LANDO_DB_ALIAS} access confirmed!" # Suppress drush messaging by assigning output echo "Destroying all current tables in database if needed... " @@ -156,7 +156,7 @@ if [ "${LANDO_FILES_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then # Validate environment exists lando_pink "Validating file alias @${LANDO_FILES_ALIAS} exists and you have access to it..." if ! drush la | grep -q ${LANDO_FILES_ALIAS}; then - lando_red "@$LANDO_FILES_ALIAS does not appear to be a valid environment!" + lando_red "@${LANDO_FILES_ALIAS} does not appear to be a valid environment!" exit 1 fi @@ -169,13 +169,13 @@ if [ "${LANDO_FILES_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then lando_green "Files alias @${LANDO_FILES_ALIAS} access confirmed!" if ! drush "@${LANDO_FILES_ALIAS}" status | grep -q "File directory path"; then - lando_red "Unable to pull files from $LANDO_FILES_ALIAS without a file directory path specified. Set up or import a database first." + lando_red "Unable to pull files from ${LANDO_FILES_ALIAS} without a file directory path specified. Set up or import a database first." exit 1 else DRUPAL_FILES_PATH=$(drush @${LANDO_FILES_ALIAS} dd files | tr -d '\n' 2>/dev/null) fi - lando_pink "Attemping to sync files to/from directory: $DRUPAL_FILES_PATH" + lando_pink "Attemping to sync files to/from directory: ${DRUPAL_FILES_PATH}" # Import files with rsync LANDO_SSH_KEY=${LANDO_SSH_KEY} drush rsync "@${LANDO_FILES_ALIAS}":${DRUPAL_FILES_PATH} ${DRUPAL_FILES_PATH} -y From be0570af90df48ea0e525da7a8f9128266d202a4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Jan 2021 07:32:23 +0000 Subject: [PATCH 009/258] Bump axios from 0.18.1 to 0.21.1 Bumps [axios](https://github.com/axios/axios) from 0.18.1 to 0.21.1. - [Release notes](https://github.com/axios/axios/releases) - [Changelog](https://github.com/axios/axios/blob/v0.21.1/CHANGELOG.md) - [Commits](https://github.com/axios/axios/compare/v0.18.1...v0.21.1) Signed-off-by: dependabot[bot] --- package.json | 2 +- yarn.lock | 19 +++++++++---------- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index f54955226..1079bc662 100644 --- a/package.json +++ b/package.json @@ -109,7 +109,7 @@ ] }, "dependencies": { - "axios": "^0.18.1", + "axios": "^0.21.1", "bluebird": "^3.4.1", "clean-stacktrace": "^1.1.0", "cli-table": "^0.3.1", diff --git a/yarn.lock b/yarn.lock index 6069f5c39..e14ae3e7e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1822,13 +1822,12 @@ axios@0.19.0: follow-redirects "1.5.10" is-buffer "^2.0.2" -axios@^0.18.1: - version "0.18.1" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.18.1.tgz#ff3f0de2e7b5d180e757ad98000f1081b87bcea3" - integrity sha512-0BfJq4NSfQXd+SkFdrvFbG7addhYSBA2mQwISr46pD6E5iqkWg02RAs8vyTT/j0RTnoYmeXauBuSv1qKwR179g== +axios@^0.21.1: + version "0.21.1" + resolved "https://registry.yarnpkg.com/axios/-/axios-0.21.1.tgz#22563481962f4d6bde9a76d516ef0e5d3c09b2b8" + integrity sha512-dKQiRHxGD9PPRIUNIWvZhPTPpl1rf/OxTYKsqKUDjBwYylTvV7SjSHJb9ratfyzM6wCdLCOYLzs73qpg5c4iGA== dependencies: - follow-redirects "1.5.10" - is-buffer "^2.0.2" + follow-redirects "^1.10.0" babel-loader@^8.0.4: version "8.0.6" @@ -4449,10 +4448,10 @@ follow-redirects@1.5.10: dependencies: debug "=3.1.0" -follow-redirects@^1.0.0: - version "1.13.0" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.13.0.tgz#b42e8d93a2a7eea5ed88633676d6597bc8e384db" - integrity sha512-aq6gF1BEKje4a9i9+5jimNFIpq4Q1WiwBToeRK5NvZBd/TRsmW8BsJfOEGkr76TbOyPVD3OVDN910EcUNtRYEA== +follow-redirects@^1.0.0, follow-redirects@^1.10.0: + version "1.13.1" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.13.1.tgz#5f69b813376cee4fd0474a3aba835df04ab763b7" + integrity sha512-SSG5xmZh1mkPGyKzjZP8zLjltIfpW32Y5QpdNJyjcfGxK3qo3NDDkZOZSFiGn1A6SclQxY9GzEwAHQ3dmYRWpg== for-in@^1.0.1, for-in@^1.0.2: version "1.0.2" From 3ce5963d59fbaa9eaf12958c022e2902e0059b41 Mon Sep 17 00:00:00 2001 From: sgurlt Date: Tue, 5 Jan 2021 12:53:48 +0100 Subject: [PATCH 010/258] Update lando-phpstorm.md Add note about deprecated xdebug.remote_port setting introduced in PHP 7.3. --- docs/guides/lando-phpstorm.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/guides/lando-phpstorm.md b/docs/guides/lando-phpstorm.md index 569b3374e..3e25b12ab 100644 --- a/docs/guides/lando-phpstorm.md +++ b/docs/guides/lando-phpstorm.md @@ -13,6 +13,12 @@ and Drupal development. This video tutorial shows you how to set up PhpStorm wit If you’ve a local php installation (for example php 7.1 installed with homebrew on macOS) that listens on port 9000 you may need to change the containers php.ini port specification to another port (i.e. `xdebug.remote_port=9001`) and tell phpstorm to listen on that port. See also [Debugging Drupal 8 with PHPstorm and Lando on your Mac](https://www.isovera.com/blog/debugging-drupal-8-phpstorm-and-lando-your-mac). +### PHP 7.3 and later +With PHP 7.3 the setting `xdebug.remote_port` has been deprecated and instead the setting `xdebug.client_port` should be used. +Also the default xdebug port changed from `9000` to `9003`. + +https://xdebug.org/docs/upgrade_guide#changed-xdebug.remote_port + ## Debugging Drush Commands By default our Drupal recipes come with Drush out of the box. In order to debug any Drush command using Xdebug using From e6d47173e701b099ada850e590fc1db57c9c8edb Mon Sep 17 00:00:00 2001 From: Fonata Date: Sat, 9 Jan 2021 21:29:16 +0100 Subject: [PATCH 011/258] services.md: type custom is actually compose --- docs/config/services.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/config/services.md b/docs/config/services.md index e83f9c2dd..13245687e 100644 --- a/docs/config/services.md +++ b/docs/config/services.md @@ -48,7 +48,7 @@ If you want to load Docker compose files **and** use services, you should note t The following services are currently supported. Please check out each one to learn how to use them. * ### [apache](./apache.md) -* ### [custom](./compose.md) +* ### [compose](./compose.md) * ### [dotnet](./dotnet.md) * ### [elasticsearch](./elasticsearch.md) * ### [go](./go.md) From b0779992ee95b2847c29880de6f3e6bf7e217fa1 Mon Sep 17 00:00:00 2001 From: Fonata Date: Sat, 9 Jan 2021 21:52:28 +0100 Subject: [PATCH 012/258] services.md: Minor language improvements --- docs/config/services.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/config/services.md b/docs/config/services.md index 13245687e..ed1991430 100644 --- a/docs/config/services.md +++ b/docs/config/services.md @@ -74,7 +74,7 @@ The following services are currently supported. Please check out each one to lea One of the great features of Lando is its ability to destroy a single planet... we mean add additional dependencies or build steps to your service without the hassle of having to build or manage your own Dockerfiles. -Note that build steps will **ONLY RUN THE FIRST TIME YOU SPIN UP YOUR APP.** That means if you change them, you will need to run `lando rebuild` for them to re-run. An exception to this is if one or more of your build steps error. When this happens Lando will run the build steps until they complete succesfully. +Note that build steps will **ONLY RUN THE FIRST TIME YOU SPIN UP YOUR APP.** That means if you change them, you will need to run `lando rebuild` for them to re-run. An exception to this is if one or more of your build steps error. When this happens Lando will run the build steps until they complete successfully. :::tip When should I use build steps? If you need additional on-server dependencies like php extensions or node modules, it sounds like a build step may be for you. If you have automation, you want to run **EVERY TIME** and you may want to consider using [events](./events.md) instead. @@ -116,7 +116,7 @@ As you can likely surmise from the above, each step is intended for a pretty spe * Use `run` to install application dependencies or run build steps that require your application be started first * Use `run_as_root` for any other post-start `root` level one-time setup commands. -Of course, these steps must make sense within the context of the container you are running them in. For example, you will not be able to run `dnf` inside of a `debian` flavored container. Also note that the default working directory that the commands run in inside the container is `/app`. +Of course, these steps must make sense within the context of the container you are running them in. For example, you will not be able to run `dnf` inside of a `debian` flavored container. Also, note that the default working directory that the commands run in inside the container is `/app`. Another potential consideration is "dependent commands". Each line of a build step runs in a separate subshell; so if COMMAND B is dependent on something provided by COMMAND A such as `sourcing` a file, you should combine the commands with `&&` and put them on a single line. @@ -163,7 +163,7 @@ Lando services are just an abstraction layer on top of the [Docker compose v3 fi We give you access to the Docker Compose layer with the `overrides` key. ::: tip You can only override Docker Compose's top-level `services` config -Overrides you specify get merged and injected directly into the `services` config used by Docker Compose. This means that you cannot use overrides to alter *top level* `networks` or `volumes`. If you are looking for that kind of **POWER**, we suggest you look at the [custom](./compose.md) service. +Overrides you specify get merged and injected directly into the `services` config used by Docker Compose. This means that you cannot use overrides to alter *top level* `networks` or `volumes`. If you are looking for that kind of **POWER**, we suggest you look at the [compose](./compose.md) service. ::: Here is an example of an overridden `apache` service that uses a custom image and injects some additional environment variables. However, you can put anything into `overrides` that you can put into the `services` config of a Docker Compose file. Note that if you change the image, your success in running with that image is directly correlated to how close that image is to the ones we use by default. For that reason, it is **highly recommended** your custom images are extended from ours so your chance of doing this with great success is maximized. @@ -217,7 +217,7 @@ services: ### Localhost Assignment -Lando will attempt to assign `localhost` addresses to any service that has ports `80` or `443` exposed. By default, this is most of our services. An exception is the [`compose`](./compose.md) service which requires the user manually expose the ports they need at the Docker Compose level. You can tell Lando to assign `localhost` addresses to additional `http` ports with the following. +Lando will attempt to assign `localhost` addresses to any service that has ports `80` or `443` exposed. By default, this is most of our services. An exception is the [`compose`](./compose.md) service which requires the user to manually expose the ports they need at the Docker Compose level. You can tell Lando to assign `localhost` addresses to additional `http` ports with the following. ```yaml services: @@ -234,7 +234,7 @@ Note that while you *can* do the above, it is highly unlikely you will *need* to ### Service URL Scanning -Lando will automatically try to scan all `localhost` and `proxy` URLS after your app starts. We do this to: +Lando will automatically try to scan all `localhost` and `proxy` URLs after your app starts. We do this to: 1. Provide some immediate feedback to the user regarding the health of their application and the routing that Lando has set up for it 2. Help compile first-run application caches behind the scenes to improve initial loaded-in-browser speed From 1f67ece5c52170e9ae3e49a09a70ca4f3e66a570 Mon Sep 17 00:00:00 2001 From: tebb Date: Mon, 11 Jan 2021 20:57:21 +0000 Subject: [PATCH 013/258] Typo: dependenices -> dependencies My screen reader says "Thank you for the challenge". --- docs/config/node.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/config/node.md b/docs/config/node.md index f957ec9f8..d2e504a80 100644 --- a/docs/config/node.md +++ b/docs/config/node.md @@ -121,7 +121,7 @@ services: ### Installing global dependencies -You can also use the `globals` key if you need to install any [global node dependenices](https://docs.npmjs.com/cli/install). This follows the same syntax as your normal [`package.json`](https://docs.npmjs.com/files/package.json) except written as YAML instead of JSON. +You can also use the `globals` key if you need to install any [global node dependencies](https://docs.npmjs.com/cli/install). This follows the same syntax as your normal [`package.json`](https://docs.npmjs.com/files/package.json) except written as YAML instead of JSON. ::: tip Use package.json if you can! While there are some legitimate use cases to globally install a node dependency, it is almost always preferred to install using your applications normal `package.json` and then running either `lando npm` or `lando yarn` or alternatively setting up a [build step](./../config/services.md#build-steps) that will automatically run before your app starts up. From e12ab0accba76e33654681ba52bf2e0f849905fe Mon Sep 17 00:00:00 2001 From: Michele Locati Date: Thu, 14 Jan 2021 11:17:49 +0100 Subject: [PATCH 014/258] Use release asset instead of unreleased script --- docs/guides/installing-php-extensions-on-lando.md | 2 +- examples/php-extensions/Dockerfile.custom | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/guides/installing-php-extensions-on-lando.md b/docs/guides/installing-php-extensions-on-lando.md index 138064829..ad48f89ed 100644 --- a/docs/guides/installing-php-extensions-on-lando.md +++ b/docs/guides/installing-php-extensions-on-lando.md @@ -94,7 +94,7 @@ services: FROM devwithlando/php:7.3-apache-2 # Add php extension helper -ADD https://raw.githubusercontent.com/mlocati/docker-php-extension-installer/master/install-php-extensions /usr/local/bin/ +ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ # Install Oracle Instantclient RUN mkdir /opt/oracle \ diff --git a/examples/php-extensions/Dockerfile.custom b/examples/php-extensions/Dockerfile.custom index 7c122d1cd..74c19c922 100644 --- a/examples/php-extensions/Dockerfile.custom +++ b/examples/php-extensions/Dockerfile.custom @@ -1,7 +1,7 @@ FROM devwithlando/php:7.3-apache-2 # Add php extension helper -ADD https://raw.githubusercontent.com/mlocati/docker-php-extension-installer/master/install-php-extensions /usr/local/bin/ +ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ # Install Oracle Instantclient RUN mkdir /opt/oracle \ From d2fbbf3155caa984c424ecb0dbf3e90f0a51f9e5 Mon Sep 17 00:00:00 2001 From: Michele Locati Date: Thu, 14 Jan 2021 11:28:47 +0100 Subject: [PATCH 015/258] install-php-extensions now supports installing oci8 (and Instant Client) --- .../installing-php-extensions-on-lando.md | 20 ++----------------- examples/php-extensions/Dockerfile.custom | 20 ++----------------- 2 files changed, 4 insertions(+), 36 deletions(-) diff --git a/docs/guides/installing-php-extensions-on-lando.md b/docs/guides/installing-php-extensions-on-lando.md index ad48f89ed..536fd87db 100644 --- a/docs/guides/installing-php-extensions-on-lando.md +++ b/docs/guides/installing-php-extensions-on-lando.md @@ -96,25 +96,9 @@ FROM devwithlando/php:7.3-apache-2 # Add php extension helper ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ -# Install Oracle Instantclient -RUN mkdir /opt/oracle \ - && cd /opt/oracle \ - && curl https://download.oracle.com/otn_software/linux/instantclient/19600/instantclient-basic-linux.x64-19.6.0.0.0dbru.zip > /opt/oracle/instantclient-basic.zip \ - && curl https://download.oracle.com/otn_software/linux/instantclient/19600/instantclient-sdk-linux.x64-19.6.0.0.0dbru.zip > /opt/oracle/instantclient-sdk.zip \ - && unzip /opt/oracle/instantclient-basic.zip -d /opt/oracle \ - && unzip /opt/oracle/instantclient-sdk.zip -d /opt/oracle \ - && rm /opt/oracle/instantclient-basic.zip \ - && rm /opt/oracle/instantclient-sdk.zip \ - # Make OS aware of newly installed libraries - && echo /opt/oracle/instantclient_19_6 > /etc/ld.so.conf.d/oracle-instantclient.conf \ - && ldconfig -v \ - # Install and enable OCI8 - && echo "instantclient,/opt/oracle/instantclient_19_6" | pecl install oci8-2.2.0 \ - && docker-php-ext-enable oci8 - -# Install Microsoft SQL Server extensions +# Install Oracle Instantclient, OCI8 and Microsoft SQL Server extensions RUN chmod +x /usr/local/bin/install-php-extensions && sync && \ - install-php-extensions sqlsrv pdo_sqlsrv + install-php-extensions oci8-2.2.0 sqlsrv pdo_sqlsrv ``` You can verify the extension was enabled by running diff --git a/examples/php-extensions/Dockerfile.custom b/examples/php-extensions/Dockerfile.custom index 74c19c922..989c5b5a9 100644 --- a/examples/php-extensions/Dockerfile.custom +++ b/examples/php-extensions/Dockerfile.custom @@ -3,22 +3,6 @@ FROM devwithlando/php:7.3-apache-2 # Add php extension helper ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ -# Install Oracle Instantclient -RUN mkdir /opt/oracle \ - && cd /opt/oracle \ - && curl https://download.oracle.com/otn_software/linux/instantclient/19600/instantclient-basic-linux.x64-19.6.0.0.0dbru.zip > /opt/oracle/instantclient-basic.zip \ - && curl https://download.oracle.com/otn_software/linux/instantclient/19600/instantclient-sdk-linux.x64-19.6.0.0.0dbru.zip > /opt/oracle/instantclient-sdk.zip \ - && unzip /opt/oracle/instantclient-basic.zip -d /opt/oracle \ - && unzip /opt/oracle/instantclient-sdk.zip -d /opt/oracle \ - && rm /opt/oracle/instantclient-basic.zip \ - && rm /opt/oracle/instantclient-sdk.zip \ - # Make OS aware of newly installed libraries - && echo /opt/oracle/instantclient_19_6 > /etc/ld.so.conf.d/oracle-instantclient.conf \ - && ldconfig -v \ - # Install and enable OCI8 - && echo "instantclient,/opt/oracle/instantclient_19_6" | pecl install oci8-2.2.0 \ - && docker-php-ext-enable oci8 - -# Install Microsoft SQL Server extensions +# Install Oracle Instantclient, OCI8 and Microsoft SQL Server extensions RUN chmod +x /usr/local/bin/install-php-extensions && sync && \ - install-php-extensions sqlsrv pdo_sqlsrv + install-php-extensions oci8 sqlsrv pdo_sqlsrv From 96adce6067010541db87e196fd14f2c963699580 Mon Sep 17 00:00:00 2001 From: einonsy <53839902+einonsy@users.noreply.github.com> Date: Thu, 14 Jan 2021 11:51:31 +0000 Subject: [PATCH 016/258] update: brew command changed as current method will fail --- docs/basics/installation.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/basics/installation.md b/docs/basics/installation.md index 840445e56..a750004e9 100644 --- a/docs/basics/installation.md +++ b/docs/basics/installation.md @@ -82,7 +82,7 @@ See: ::: 1. Ensure homebrew is installed and up-to-date. -2. Add the lando cask: `brew cask install lando` +2. Add the lando cask: `brew install --cask lando` ## Linux From 1acb2fcb7e51f60a954fb2d65d292e182106bdc9 Mon Sep 17 00:00:00 2001 From: Dustin LeBlanc Date: Tue, 19 Jan 2021 09:26:18 -0500 Subject: [PATCH 017/258] First draft of WSL2 guide --- docs/.vuepress/guides.json | 43 ++++++------ .../setup-lando-on-windows-with-wsl-2.md | 69 +++++++++++++++++++ 2 files changed, 91 insertions(+), 21 deletions(-) create mode 100644 docs/guides/setup-lando-on-windows-with-wsl-2.md diff --git a/docs/.vuepress/guides.json b/docs/.vuepress/guides.json index 422d0895c..7a01b58eb 100644 --- a/docs/.vuepress/guides.json +++ b/docs/.vuepress/guides.json @@ -1,23 +1,4 @@ [ - { - "title": "Lando Courses", - "collapsable": false, - "children": [ - { - "title": "Lando 101", - "collapsable": true, - "children": [ - "lando-101/lando-overview", - "lando-101/lando-init", - "lando-101/lando-start", - "lando-101/lando-config", - "lando-101/lando-services", - "lando-101/lando-proxy", - "lando-101/lando-tooling" - ] - } - ] - }, { "title": "Databases", "collapsable": false, @@ -39,7 +20,8 @@ "children": [ "how-do-i-configure-a-lando-recipe", "how-do-i-set-the-timezone-of-a-lando-service", - "lando-info" + "lando-info", + "setup-lando-on-windows-with-wsl-2" ] }, { @@ -50,6 +32,25 @@ "lando-with-vscode" ] }, + { + "title": "Lando Courses", + "collapsable": false, + "children": [ + { + "title": "Lando 101", + "collapsable": true, + "children": [ + "lando-101/lando-overview", + "lando-101/lando-init", + "lando-101/lando-start", + "lando-101/lando-config", + "lando-101/lando-services", + "lando-101/lando-proxy", + "lando-101/lando-tooling" + ] + } + ] + }, { "title": "Networking", "collapsable": false, @@ -120,4 +121,4 @@ "updating-to-rc2" ] } -] +] \ No newline at end of file diff --git a/docs/guides/setup-lando-on-windows-with-wsl-2.md b/docs/guides/setup-lando-on-windows-with-wsl-2.md new file mode 100644 index 000000000..7d56a7e56 --- /dev/null +++ b/docs/guides/setup-lando-on-windows-with-wsl-2.md @@ -0,0 +1,69 @@ +--- +title: Setup Lando on Windows with WSL2 +metaTitle: Setup Lando on Windows with WSL2 | Lando +description: Configure Lando to run on your Windows WSL2 system for better performance when developing on Windows. +summary: Configure Lando to run on your Windows WSL2 system for better performance when developing on Windows. +date: 2021-01-19T14:21:27.061Z +original: +repo: + +author: + name: Dustin LeBlanc + pic: https://www.gravatar.com/avatar/e61caccbbfd817bc8b52c0395ba888a6 + link: https://twitter.com/DustinLeblanc + +feed: + enable: true + author: + - name: Dustin LeBlanc + email: dustin@dustinleblanc.com + link: https://twitter.com/DustinLeblanc + contributor: + - name: Dustin LeBlanc + email: alliance@lando.dev + link: https://twitter.com/DustinLeblanc +--- + +# Setup Lando on Windows with WSL2 + + + + +Windows Development used to be something that caused most web developers agony and pain, but with the introduction of WSL, this is no longer quite so. With the introduction of WSL2, Microsoft has given us a near-native Linux experience for developing web applications using WSL2. + +Long time Mac or Windows Lando users will be familiar with the long standing performance difficulties associated with file system access when using Docker in a non-linux host environment. WSL2 manages to bypass the majority of this performance penalty by never mounting your source code on a non-linux filesystem. Here is the best (highest performance) way to setup Docker (and Lando) on a Windows 10 machine in 2021: + +## Pre-Req + +You will want to make sure that if you have an existing Docker or WSL setup, that you are **not** using the Docker + WSL2 backend. If you have this setup, things are going to get funky and break. It is very sad, very frustrating, so if you are here, do yourself a favor and uninstall the Docker Desktop WSL2 backend. + +You also need to ensure your machine supports virtualization (Vt-d, etc.). You don't need to have Windows 10 pro like the traditional Lando on Windows setup, as WSL doesn't require it. + +## Get WSL2 rolling + +The first thing we need to do is enable WSL2. to do so, open the start menu and search for "Turn Windows features on or off". In the resulting window, we want to check 'Windows Subsystem for Linux' and 'Virtual Machine Platform' and then click 'ok'. This starts the system installed for WSL and will ask us to restart after it downloads the stuff it needs. This really only gives you the WSL1 setup, and you need to download a kernel update to get WSL2 going, see the (Microsoft docs on installing the kernel update)[https://docs.microsoft.com/en-us/windows/wsl/install-win10#step-4---download-the-linux-kernel-update-package]. + +After you install the kernel update, make sure to launch a powershell and run `wsl --set-default-version 2` to default to WSL 2. + +After installing the kernel update, its time to head to the Microsoft store and install a Linux distro. I am going to choose Ubuntu 18.04 LTS, since it is the most common distro for Lando users and our handy (Hyperdrive)[https://github.com/lando/hyperdrive] supports it. + +## Jump into Hyperspace + +After installing the latest LTS Ubuntu, using Hyperdrive makes the rest extremely easy. We simply lauch a bash shell in the WSL instance, follow the user setup process, and then follow the hyperdrive instructions. + +## Rules to keep your setup easy and happy + +1. **never** run a lando app from within the default directory that WSL drops you into (`/mnt/c/Users/whateveruser`). This is the Windows filesystem mounted into your WSL instance, and it suffers from the filesystem performance issues that this setup avoids, therefore making going through the trouble of setting this up pointless. +2. You have to start Docker every time you start up the WSL2 instance. I just run `sudo service docker start` but you can probably do some `.bashrc` magic to do this automatically. This is because the WSL2 distros have no init system, so docker doesn't auto start. +3. VS Code is the absolute easiest editor to use with this setup. Microsoft has some extensions that make working with your WSL filesystem very easy. Vim/Neovim also work great, but using an editor like PHPStorm currently requires some extra setup if you want decent performance. + +## Day to day development + +You'll want to do all of your shell activity from within the WSL system, and you treat it generally just like a linux development box. You can run `code .` from the directory of any project you're working on and it will lauch VS Code, properly setup to develop within WSL. If you launch the terminal within WSL, it is going to work just like you expect and open the session within the WSL system. + +## Some caveats + +Performance is generally very good with this approach, however, stability can at times leave something to be be desired. Occassional freezes under heavy load are fairly common place, and seem to be resolved by rebooting the system. All things considered, the reduction in CPU load, battery drain, and the accompanied increase in the speed of every single action you take (accessing site pages, running any CLI commands) more than outweighs the disruption of these occasional issues for most users. Hopefully stability will continue to increase with time + + + From 15094deca5f3c02c5e593bcd03793552620b1e4e Mon Sep 17 00:00:00 2001 From: Mike Milano Date: Tue, 19 Jan 2021 11:13:11 -0800 Subject: [PATCH 018/258] Initialized lando-acquia plugin. --- experimental/lando-acquia/index.js | 4 ++++ .../lando-acquia/recipes/acquia/init.js | 24 +++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 experimental/lando-acquia/index.js create mode 100644 experimental/lando-acquia/recipes/acquia/init.js diff --git a/experimental/lando-acquia/index.js b/experimental/lando-acquia/index.js new file mode 100644 index 000000000..800ef17e1 --- /dev/null +++ b/experimental/lando-acquia/index.js @@ -0,0 +1,4 @@ +'use strict'; + +module.exports = () => ({ +}); diff --git a/experimental/lando-acquia/recipes/acquia/init.js b/experimental/lando-acquia/recipes/acquia/init.js new file mode 100644 index 000000000..01532a557 --- /dev/null +++ b/experimental/lando-acquia/recipes/acquia/init.js @@ -0,0 +1,24 @@ +'use strict'; + +module.exports = { + name: 'acquia', + overrides: { + // Suppress webroot prompt + webroot: { + when: () => false, + }, + }, + options: lando => ({ + 'foo': { + describe: 'Testing option for the acquia recipe', + string: true, + interactive: { + type: 'list', + choices: {name: 'Bar', value: 'bar'}, + message: 'Select a foo', + weight: 100, + when: true, + }, + }, + }), +}; From 4940cd17ca3c579584d8ebb908fa099549338c73 Mon Sep 17 00:00:00 2001 From: Thomas Deinhamer <184284+thasmo@users.noreply.github.com> Date: Fri, 22 Jan 2021 18:30:00 +0100 Subject: [PATCH 019/258] Update LEMP example for custom config files --- docs/config/lemp.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/config/lemp.md b/docs/config/lemp.md index aae90f91c..567812140 100644 --- a/docs/config/lemp.md +++ b/docs/config/lemp.md @@ -166,6 +166,8 @@ Note that you can put your configuration files anywhere inside your application recipe: lemp config: config: + server: config/nginx.conf + vhosts: config/default.conf php: config/php.ini database: config/my-custom.cnf ``` From a35f83bcfc1e927c9a920f4773e18202eef01f8a Mon Sep 17 00:00:00 2001 From: Alec Reynolds Date: Mon, 25 Jan 2021 14:37:42 -0800 Subject: [PATCH 020/258] Add mention of M1 mac support --- docs/basics/installation.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/basics/installation.md b/docs/basics/installation.md index 840445e56..e28827a1a 100644 --- a/docs/basics/installation.md +++ b/docs/basics/installation.md @@ -44,6 +44,10 @@ We've found the below or better to deliver the best experience. * 16GB+ RAM * 100GB+ of available disk space +::: tip Apple Silicon M1 Chip Support +Docker is [working on support](docker.com/blog/apple-silicon-m1-chips-and-docker) for Mac computers running Apple Silicon M1 chips. We've been monitoring their progress and plan to introduce an M1-compatible Lando binary as soon as possible. [Sponsor Lando](https://github.com/sponsors/lando) to make that world a reality! +::: + ## Preflight Checks 1. Verify that your system meets the [minimum system and hardware requirements](#system-requirements) to run Lando. From 8a010f5293f4b5bdbd4027a86a141a7366aded0d Mon Sep 17 00:00:00 2001 From: Mike Milano Date: Mon, 25 Jan 2021 18:16:54 -0800 Subject: [PATCH 021/258] Lando cloud api init & build work --- experimental/lando-acquia/index.js | 1 + experimental/lando-acquia/lib/api.js | 91 ++++++++++++++ experimental/lando-acquia/lib/utils.js | 29 +++++ .../lando-acquia/recipes/acquia/builder.js | 44 +++++++ .../lando-acquia/recipes/acquia/init.js | 118 ++++++++++++++++-- 5 files changed, 271 insertions(+), 12 deletions(-) create mode 100644 experimental/lando-acquia/lib/api.js create mode 100644 experimental/lando-acquia/lib/utils.js create mode 100644 experimental/lando-acquia/recipes/acquia/builder.js diff --git a/experimental/lando-acquia/index.js b/experimental/lando-acquia/index.js index 800ef17e1..03e76554c 100644 --- a/experimental/lando-acquia/index.js +++ b/experimental/lando-acquia/index.js @@ -1,4 +1,5 @@ 'use strict'; module.exports = () => ({ + name: 'acquia', }); diff --git a/experimental/lando-acquia/lib/api.js b/experimental/lando-acquia/lib/api.js new file mode 100644 index 000000000..a14de49b6 --- /dev/null +++ b/experimental/lando-acquia/lib/api.js @@ -0,0 +1,91 @@ +'use strict'; + +// Modules +const _ = require('lodash'); +const axios = require('axios'); + +module.exports = class AcquiaApi { + constructor() { + axios.defaults.baseURL = 'https://cloud.acquia.com/api/'; + + this.authURL = 'https://accounts.acquia.com/api/auth/oauth/token'; + // this.apiURL = 'https://cloud.acquia.com/api'; + this.token = null; + this.account = null; + this.applications = null; + } + + /** + * Sets both token and account; Uses original values if called more than once. + * @param {string} clientId Acquia client key + * @param {string} clientSecret Acquia client secret + * @param {bool} force Cache buster + * @return {Promise} + */ + auth(clientId, clientSecret, force = false) { + // @see https://docs.acquia.com/cloud-platform/develop/api/auth/#making-api-calls-through-single-sign-on + if (!force && this.token !== null) { + return new this.lando.Promise(this.account); + } + // Clear account to assure the account on this object + // matches the token if auth is run more than once. + return axios.post(this.authURL, { + client_id: clientId, + client_secret: clientSecret, + grant_type: 'client_credentials', + scope: '', + }) + .then(res => { + // Set token and auth headers + this.token = res.data; + axios.defaults.headers.common = {'Authorization': `Bearer ${this.token.access_token}`}; + }) + .catch(err => { + throw err.response.data.error_description; + }).then(() => { + return this.getAccount().then(data => { + this.account = data; + return this.account; + }); + }); + } + + /** + * Sets this.applications + * @return {Promise} Acquia applications array + */ + getApplications() { + if (this.applications !== null) { + return new lando.Promise(this.applications); + } + return axios.get('https://cloud.acquia.com/api/applications').then(res => { + const total = res.data.total; + this.applications = total === 0 ? [] : res.data._embedded.items.map(item => ({ + id: item.id, + uuid: item.uuid, + subuuid: item.subscription.uuid, + name: item.subscription.name, + })); + return this.applications; + }) + .catch(error => { + console.log(error); + }); + } + + /** + * Sets this.account; Called in this.auth(). + * @return {Promise} + */ + getAccount() { + if (this.account !== null) { + return new lando.Promise(this.account); + } + return axios.get('https://cloud.acquia.com/api/account').then(res => { + this.account = res.data; + return this.account; + }).catch(error => { + console.log(error); + }); + } +}; diff --git a/experimental/lando-acquia/lib/utils.js b/experimental/lando-acquia/lib/utils.js new file mode 100644 index 000000000..0a23dfb00 --- /dev/null +++ b/experimental/lando-acquia/lib/utils.js @@ -0,0 +1,29 @@ +'use strict'; + +// Modules +const _ = require('lodash'); +const fs = require('fs'); +const path = require('path'); + +/* + * Helper to get terminus tokens + */ +exports.getAcquiaTokens = home => { + if (fs.existsSync(path.join(home, '.acquia', 'cache', 'tokens'))) { + return _(fs.readdirSync(path.join(home, '.acquia', 'cache', 'tokens'))) + .map(tokenFile => path.join(home, '.acquia', 'cache', 'tokens', tokenFile)) + .map(file => JSON.parse(fs.readFileSync(file, 'utf8'))) + .value(); + } else { + return []; + } +}; + +/* + * Helper to return most recent tokens + */ +exports.sortTokens = (...sources) => _(_.flatten([...sources])) + .sortBy('date') + .groupBy('email') + .map(tokens => _.last(tokens)) + .value(); diff --git a/experimental/lando-acquia/recipes/acquia/builder.js b/experimental/lando-acquia/recipes/acquia/builder.js new file mode 100644 index 000000000..e9c56e0bd --- /dev/null +++ b/experimental/lando-acquia/recipes/acquia/builder.js @@ -0,0 +1,44 @@ +'use strict'; + +// Modules +const _ = require('lodash'); + +module.exports = { + name: 'acquia', + parent: '_drupaly', + config: { + confSrc: __dirname, + defaultFiles: {}, + php: '7.4', + drush: '^10', + }, + builder: (parent, config) => class LandoDrupal9 extends parent { + constructor(id, options = {}) { + options = _.merge({}, config, options); + options.drush = false; + options.database = 'mysql:5.7'; + // Load .env file. + options.env_file = ['.env']; + // Set build steps for app server. + options.services = { + appserver: { + build: [ + 'curl -OL https://github.com/acquia/cli/releases/latest/download/acli.phar', + 'chmod +x acli.phar', + 'mv acli.phar /usr/local/bin/acli', + '/usr/local/bin/acli auth:login -k $ACLI_KEY -s $ACLI_SECRET -n', + ], + }, + }; + // Add acli tooling. + options.tooling = { + 'acli': { + service: 'appserver', + description: 'Run the Acquia acli command', + cmd: 'acli', + }, + }; + super(id, options); + }; + }, +}; diff --git a/experimental/lando-acquia/recipes/acquia/init.js b/experimental/lando-acquia/recipes/acquia/init.js index 01532a557..f996e6bed 100644 --- a/experimental/lando-acquia/recipes/acquia/init.js +++ b/experimental/lando-acquia/recipes/acquia/init.js @@ -1,24 +1,118 @@ 'use strict'; +const _ = require('lodash'); +const API = require('../../lib/api'); +const utils = require('../../lib/utils'); + +// Acquia +const api = new API(); +const acquiaTokenCache = 'acquia.tokens'; +const acquiaApps = []; + +// Helper to get tokens +const getTokens = (home, tokens = []) => _(utils.sortTokens(utils.getAcquiaTokens(home), tokens)) + .map(token => ({name: token.email, value: token.token})) + .thru(tokens => tokens.concat([{name: 'add or refresh a token', value: 'more'}])) + .value(); + +// Helper to determine whether to show list of pre-used tokens or not +const showTokenList = (recipe, tokens = []) => recipe === 'acquia' && !_.isEmpty(tokens); + +// Helper to determine whether to show token password entry or not +const showTokenEntry = (data, answer, tokens = []) => data === 'acquia' && (_.isEmpty(tokens) || answer === 'more'); + +const getAutoCompleteSites = (answers, lando, input = null) => { + if (!_.isEmpty(acquiaApps)) { + return lando.Promise.resolve(acquiaApps).filter(app => _.startsWith(app.name, input)); + } + return api.getApplications().then(apps => { + if (apps && Array.isArray(apps)) { + apps.map(item => acquiaApps.push({name: item.name, value: item.name})); + return lando.Promise.resolve(acquiaApps); + } + }); +}; + module.exports = { name: 'acquia', - overrides: { - // Suppress webroot prompt - webroot: { - when: () => false, - }, - }, options: lando => ({ - 'foo': { - describe: 'Testing option for the acquia recipe', + 'acquia-auth': { + describe: 'Acquia API Key', string: true, interactive: { type: 'list', - choices: {name: 'Bar', value: 'bar'}, - message: 'Select a foo', - weight: 100, - when: true, + choices: getTokens(lando.config.home, lando.cache.get(acquiaTokenCache)), + message: 'Select your Acquia API key', + when: answers => { + return showTokenList(answers.recipe, lando.cache.get(acquiaTokenCache)); + }, + weight: 510, + }, + }, + 'acquia-key': { + hidden: false, + interactive: { + name: 'acquia-key', + type: 'password', + message: 'Enter your Acquia API key', + when: answers => { + return showTokenEntry(answers.recipe, answers['acquia-auth'], lando.cache.get(acquiaTokenCache)); + }, + weight: 520, + }, + }, + 'acquia-secret': { + hidden: true, + interactive: { + name: 'acquia-secret', + type: 'password', + message: 'Enter your Acquia API secret', + when: answers => { + return true; + // return showTokenEntry(answers.recipe, answers['acquia-auth'], lando.cache.get(acquiaTokenCache)); + }, + validate: (input, answers) => { + return api.auth(answers['acquia-key'], input).then(() => { + return true; + }).catch(err => { + return err; + }); + }, + weight: 530, + }, + }, + 'acquia-app': { + describe: 'An Acquia site ID', + string: true, + interactive: { + type: 'autocomplete', + message: 'Which site?', + source: (answers, input) => { + // console.log('**', acquiaApps); + return getAutoCompleteSites(answers, lando, input); + }, + when: answers => answers.recipe === 'acquia', + weight: 540, }, }, }), + overrides: { + name: { + when: answers => { + answers.name = answers['acquia-app']; + return false; + }, + }, + webroot: { + when: () => false, + }, + }, + sources: [{ + name: 'acquia', + label: 'acquia', + }], + build: (options, lando) => { + return { + }; + }, }; From a4a2218593c4b7cb8a6edd393ce336a608107cbc Mon Sep 17 00:00:00 2001 From: Xaq Rothman Date: Wed, 27 Jan 2021 12:28:54 -0500 Subject: [PATCH 022/258] Adding xaqrox to the team. --- contributors.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/contributors.yml b/contributors.yml index b678406e3..00a76250b 100644 --- a/contributors.yml +++ b/contributors.yml @@ -191,3 +191,10 @@ title: Contributor pic: 'https://www.gravatar.com/avatar/b497056d7679e425fdb3d6f7fca7d05b' id: a42fa56eb47d917eeb086338cdc37efb635bef51 +- name: Xaq Rothman + location: 'Washington, D.C.' + github: xaqrox + twitter: xaqrox + title: Contributor + pic: 'https://www.gravatar.com/avatar/c335f31e62b453f747f39a84240b3bbd' + id: 443e9ca6ae16555ec9d336447aaac3a944eebf5b From 51f293b805ec14cd94d601dc00c6e7e1a3f366ac Mon Sep 17 00:00:00 2001 From: Xaq Rothman Date: Wed, 27 Jan 2021 12:30:31 -0500 Subject: [PATCH 023/258] #2812: Scoot platform local deps to top of PATH. --- .../types/platformsh-appserver/builder.js | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/integrations/lando-platformsh/types/platformsh-appserver/builder.js b/integrations/lando-platformsh/types/platformsh-appserver/builder.js index c5f12dbad..a2f7942ad 100644 --- a/integrations/lando-platformsh/types/platformsh-appserver/builder.js +++ b/integrations/lando-platformsh/types/platformsh-appserver/builder.js @@ -6,6 +6,15 @@ const path = require('path'); // Path const LANDO_PATH = [ + // BUILD deps + '/app/.platform/local/deps/nodejs/node_modules/.bin', + '/app/.platform/local/deps/php/vendor/bin', + // /app/.platform/local/deps/python + '/app/.platform/local/deps/ruby/bin', + // GLOBAL things + '/var/www/.platform/bin', + '/var/www/.platformsh/bin', + '/var/www/.composer/vendor/bin', '/app/vendor/bin', '/app/bin', '/usr/local/sbin', @@ -14,15 +23,6 @@ const LANDO_PATH = [ '/usr/bin', '/sbin', '/bin', - // GLOBAL things - '/var/www/.platform/bin', - '/var/www/.platformsh/bin', - '/var/www/.composer/vendor/bin', - // BUILD deps - '/app/.platform/local/deps/nodejs/node_modules/.bin', - '/app/.platform/local/deps/php/vendor/bin', - // /app/.platform/local/deps/python - '/app/.platform/local/deps/ruby/bin', ]; /* From f2e5f94e0f0ee4e44547aa2a1d257477a8333bf7 Mon Sep 17 00:00:00 2001 From: Jari Nousiainen Date: Thu, 28 Jan 2021 22:11:55 +0200 Subject: [PATCH 024/258] Updated Redis documentation to match code In `plugins/lando-services/services/redis/builder.js` Redis version is defined as `['6', '5', '5.0', '4', '4.0', '2.8']`. This causes an error "redis version 6.0 is not supported" if a user configures their Redis service as `type: redis:6.0`. I suggest matching the docs to code. --- docs/config/redis.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/config/redis.md b/docs/config/redis.md index adcbec9aa..01026ae9d 100644 --- a/docs/config/redis.md +++ b/docs/config/redis.md @@ -12,7 +12,7 @@ You can easily add it to your Lando app by adding an entry to the [services](./. ## Supported versions -* [6.0](https://hub.docker.com/_/redis) +* [6](https://hub.docker.com/_/redis) * **[5](https://hub.docker.com/_/redis)** **(default)** * [5.0](https://hub.docker.com/_/redis) * [4](https://hub.docker.com/_/redis) From 6905b20853e475a59a3ecdffe7bc03fd0f55ce42 Mon Sep 17 00:00:00 2001 From: Mike Milano Date: Thu, 28 Jan 2021 15:05:52 -0800 Subject: [PATCH 025/258] Acquia init work --- experimental/lando-acquia/lib/api.js | 6 +-- experimental/lando-acquia/lib/utils.js | 15 +++--- .../lando-acquia/recipes/acquia/init.js | 51 +++++++++++++++---- 3 files changed, 48 insertions(+), 24 deletions(-) diff --git a/experimental/lando-acquia/lib/api.js b/experimental/lando-acquia/lib/api.js index a14de49b6..747f60819 100644 --- a/experimental/lando-acquia/lib/api.js +++ b/experimental/lando-acquia/lib/api.js @@ -1,13 +1,11 @@ 'use strict'; - // Modules -const _ = require('lodash'); const axios = require('axios'); module.exports = class AcquiaApi { - constructor() { + constructor(lando) { + this.lando = lando; axios.defaults.baseURL = 'https://cloud.acquia.com/api/'; - this.authURL = 'https://accounts.acquia.com/api/auth/oauth/token'; // this.apiURL = 'https://cloud.acquia.com/api'; this.token = null; diff --git a/experimental/lando-acquia/lib/utils.js b/experimental/lando-acquia/lib/utils.js index 0a23dfb00..bdf1333c1 100644 --- a/experimental/lando-acquia/lib/utils.js +++ b/experimental/lando-acquia/lib/utils.js @@ -6,17 +6,14 @@ const fs = require('fs'); const path = require('path'); /* - * Helper to get terminus tokens + * Get acli token from host */ -exports.getAcquiaTokens = home => { - if (fs.existsSync(path.join(home, '.acquia', 'cache', 'tokens'))) { - return _(fs.readdirSync(path.join(home, '.acquia', 'cache', 'tokens'))) - .map(tokenFile => path.join(home, '.acquia', 'cache', 'tokens', tokenFile)) - .map(file => JSON.parse(fs.readFileSync(file, 'utf8'))) - .value(); - } else { - return []; +exports.getAcquiaToken = home => { + const file = path.join(home, '.acquia', 'cloud_api.conf'); + if (fs.existsSync(file)) { + return JSON.parse(fs.readFileSync(file, 'utf8')); } + return null; }; /* diff --git a/experimental/lando-acquia/recipes/acquia/init.js b/experimental/lando-acquia/recipes/acquia/init.js index f996e6bed..e7e8128af 100644 --- a/experimental/lando-acquia/recipes/acquia/init.js +++ b/experimental/lando-acquia/recipes/acquia/init.js @@ -10,10 +10,17 @@ const acquiaTokenCache = 'acquia.tokens'; const acquiaApps = []; // Helper to get tokens -const getTokens = (home, tokens = []) => _(utils.sortTokens(utils.getAcquiaTokens(home), tokens)) - .map(token => ({name: token.email, value: token.token})) - .thru(tokens => tokens.concat([{name: 'add or refresh a token', value: 'more'}])) - .value(); +const getTokens = (lando, tokens = []) => { + const home = lando.config.home; + const hostToken = utils.getAcquiaToken(home); + if (hostToken && _.isEmpty(tokens)) { + lando.cache.set(acquiaTokenCache, [hostToken], {persist: true}); + } + return _(utils.sortTokens(tokens)) + .map(token => ({name: token.key, value: token.key})) + .thru(tokens => tokens.concat([{name: 'add a token', value: 'more'}])) + .value(); +}; // Helper to determine whether to show list of pre-used tokens or not const showTokenList = (recipe, tokens = []) => recipe === 'acquia' && !_.isEmpty(tokens); @@ -41,11 +48,9 @@ module.exports = { string: true, interactive: { type: 'list', - choices: getTokens(lando.config.home, lando.cache.get(acquiaTokenCache)), + choices: getTokens(lando, lando.cache.get(acquiaTokenCache)), message: 'Select your Acquia API key', - when: answers => { - return showTokenList(answers.recipe, lando.cache.get(acquiaTokenCache)); - }, + when: answers => showTokenList(answers.recipe, lando.cache.get(acquiaTokenCache)), weight: 510, }, }, @@ -56,6 +61,22 @@ module.exports = { type: 'password', message: 'Enter your Acquia API key', when: answers => { + // If a token was selected, attempt to login. + if (answers['acquia-auth'] && answers['acquia-auth'] !== 'more') { + const token = _.find(lando.cache.get(acquiaTokenCache), token => token.key === answers['acquia-auth']); + if (token) { + answers['acquia-key'] = token.key; + answers['acquia-secret'] = token.secret; + return api.auth(answers['acquia-key'], answers['acquia-secret']).then(() => { + return false; + }).catch(err => { + // Clear out token data and prompt user. + answers['acquia-key'] = null; + answers['acquia-secret'] = null; + return true; + }); + } + } return showTokenEntry(answers.recipe, answers['acquia-auth'], lando.cache.get(acquiaTokenCache)); }, weight: 520, @@ -68,11 +89,20 @@ module.exports = { type: 'password', message: 'Enter your Acquia API secret', when: answers => { - return true; - // return showTokenEntry(answers.recipe, answers['acquia-auth'], lando.cache.get(acquiaTokenCache)); + return showTokenEntry(answers.recipe, answers['acquia-auth'], lando.cache.get(acquiaTokenCache)); }, validate: (input, answers) => { return api.auth(answers['acquia-key'], input).then(() => { + let token = _.find(lando.cache.get(acquiaTokenCache), token => token.key === answers['acquia-key']); + if (!token) { + // Re-create the token as acli would so acli can use it in a container. + token = { + send_telemetry: false, + key: answers['acquia-key'], + secret: answers['acquia-secret'], + }; + lando.cache.set(acquiaTokenCache, [token], {persist: true}); + } return true; }).catch(err => { return err; @@ -88,7 +118,6 @@ module.exports = { type: 'autocomplete', message: 'Which site?', source: (answers, input) => { - // console.log('**', acquiaApps); return getAutoCompleteSites(answers, lando, input); }, when: answers => answers.recipe === 'acquia', From 4f13faa6b8e5e2b1d6bec54e247c3d0fa18ecbed Mon Sep 17 00:00:00 2001 From: Nick Dickinson-Wilde Date: Fri, 29 Jan 2021 16:10:15 -0800 Subject: [PATCH 026/258] Update wkhtmltopdf version to match current version on Pantheon --- integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md | 2 +- integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile | 2 +- integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md | 2 +- 16 files changed, 16 insertions(+), 16 deletions(-) diff --git a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile index 9f6aea8d4..04ce5aed7 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:5.3-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.2 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV MAVEN_VERSION 3.5.4 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md index c07aa29e0..fe5c4f60e 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:5.3-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.2 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV MAVEN_VERSION 3.5.4 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile index f73be8450..77a8a5b01 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:5.5-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.2 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md index 9be50d8e2..0cb514314 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:5.5-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.2 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile index 28f9a67b3..9ee790b78 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:5.6-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md index 84710f64f..b78074f14 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:5.6-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile index 05f2bcda8..fb29f3723 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:7.0-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md index 5c4483272..1b967c337 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:7.0-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile index e4399632a..3f9b72c27 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:7.1-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md index 02d52f015..6de5d9bb8 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:7.1-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile index daa3a4d4d..930481819 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:7.2-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md index 721d225f7..7f094672d 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:7.2-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile index c50d813c2..d6e96825f 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:7.3-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md index 8c002cb98..1784b1ff4 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:7.3-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile index 9082944e8..a75bb75e6 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:7.4-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 diff --git a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md index b2d9e1d00..3f7759afb 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:7.4-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.3 +ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV LANDO_TERMINUS_VERSION 2.4.1 From 894956f23b5b18d0d3385a8d8379f4a1a2ef7658 Mon Sep 17 00:00:00 2001 From: Nick Dickinson-Wilde Date: Fri, 29 Jan 2021 16:14:05 -0800 Subject: [PATCH 027/258] Changelog update --- docs/help/2020-changelog.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index bde4f09bd..5547af606 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -1,5 +1,7 @@ # 2020 +* updated `pantheon` recipe to use `wkhtmltopdf` version 0.12.5 + ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). From bac6ebe463a73df8225cd39ab2065220c7a44b82 Mon Sep 17 00:00:00 2001 From: Jari Nousiainen Date: Sat, 30 Jan 2021 13:14:25 +0200 Subject: [PATCH 028/258] Add 6.0 to supported redis versions --- plugins/lando-services/services/redis/builder.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/lando-services/services/redis/builder.js b/plugins/lando-services/services/redis/builder.js index 8a8f06805..76730de72 100644 --- a/plugins/lando-services/services/redis/builder.js +++ b/plugins/lando-services/services/redis/builder.js @@ -8,7 +8,7 @@ module.exports = { name: 'redis', config: { version: '5', - supported: ['6', '5', '5.0', '4', '4.0', '2.8'], + supported: ['6', '6.0', '5', '5.0', '4', '4.0', '2.8'], patchesSupported: true, confSrc: __dirname, persist: false, From 04f577f4d060d01742b88484ec4d2852854be952 Mon Sep 17 00:00:00 2001 From: Jari Nousiainen Date: Sat, 30 Jan 2021 13:15:46 +0200 Subject: [PATCH 029/258] Add Redis 6.0 to docs support list --- docs/config/redis.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/config/redis.md b/docs/config/redis.md index 01026ae9d..64912d78e 100644 --- a/docs/config/redis.md +++ b/docs/config/redis.md @@ -13,6 +13,7 @@ You can easily add it to your Lando app by adding an entry to the [services](./. ## Supported versions * [6](https://hub.docker.com/_/redis) +* [6.0](https://hub.docker.com/_/redis) * **[5](https://hub.docker.com/_/redis)** **(default)** * [5.0](https://hub.docker.com/_/redis) * [4](https://hub.docker.com/_/redis) From 812ca06c812fc29cb740dc7804a130ea8f86f379 Mon Sep 17 00:00:00 2001 From: Brian Adams Date: Sun, 31 Jan 2021 03:31:30 -0500 Subject: [PATCH 030/258] Check if global composer exists before running global command --- plugins/lando-services/scripts/install-composer.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/plugins/lando-services/scripts/install-composer.sh b/plugins/lando-services/scripts/install-composer.sh index e61e78966..24ece3aa2 100644 --- a/plugins/lando-services/scripts/install-composer.sh +++ b/plugins/lando-services/scripts/install-composer.sh @@ -27,7 +27,10 @@ fi # Remove the setup script php -r "unlink('/tmp/composer-setup.php');" -# If this is version 2 then let's make sure hirak/prestissimo is removed -if composer --version 2>/dev/null | grep "Composer version 2." > /dev/null; then - composer global remove hirak/prestissimo +#Check if anything is installed globally +if [ -f /var/www/.composer/composer.json]; then + # If this is version 2 then let's make sure hirak/prestissimo is removed + if composer --version 2>/dev/null | grep "Composer version 2." > /dev/null; then + composer global remove hirak/prestissimo + fi fi From d7d8e51f60f58e54245bb0a9e8fea508925d0673 Mon Sep 17 00:00:00 2001 From: Brian Adams Date: Sun, 31 Jan 2021 03:38:47 -0500 Subject: [PATCH 031/258] Fix spacing issue --- plugins/lando-services/scripts/install-composer.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/lando-services/scripts/install-composer.sh b/plugins/lando-services/scripts/install-composer.sh index 24ece3aa2..bf19a2e2a 100644 --- a/plugins/lando-services/scripts/install-composer.sh +++ b/plugins/lando-services/scripts/install-composer.sh @@ -28,7 +28,7 @@ fi php -r "unlink('/tmp/composer-setup.php');" #Check if anything is installed globally -if [ -f /var/www/.composer/composer.json]; then +if [ -f /var/www/.composer/composer.json ]; then # If this is version 2 then let's make sure hirak/prestissimo is removed if composer --version 2>/dev/null | grep "Composer version 2." > /dev/null; then composer global remove hirak/prestissimo From ea4428b80d8f6642578aa179a368615356874cdb Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 09:50:53 -0500 Subject: [PATCH 032/258] #2729: Fix bug causing composer install to fail on php 8.0 --- docs/help/2020-changelog.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index bde4f09bd..0c52100dc 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -1,5 +1,12 @@ # 2020 +## v3.0.25 - In development + +Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). + +* Added `6.0` to list of supported `redis` versions +* Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) + ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). From f150ab1e283410b627a024eabe9410435ca544d6 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 11:00:44 -0500 Subject: [PATCH 033/258] #2820: Fixed bug causing nvm installed node versions to not load correctly in platformsh recipe when invoked via tooling --- docs/help/2020-changelog.md | 1 + integrations/lando-platformsh/scripts/psh-exec.sh | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index dd7657cdb..bb71f0d99 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -5,6 +5,7 @@ Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). * Added `6.0` to list of supported `redis` versions +* Fixed bug causing `nvm` installed `node` versions to not load correctly in `platform.sh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) * Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` diff --git a/integrations/lando-platformsh/scripts/psh-exec.sh b/integrations/lando-platformsh/scripts/psh-exec.sh index 6cc5c6a54..486fb0714 100755 --- a/integrations/lando-platformsh/scripts/psh-exec.sh +++ b/integrations/lando-platformsh/scripts/psh-exec.sh @@ -15,6 +15,11 @@ export USER="web" export SHELL="/bin/dash" export LANG="C.UTF-8" +# Also load BASHRC for things like nvm +if [ -r "$HOME/.bashrc" ] ; then + . "$HOME/.bashrc" +fi + # If we are running platform CLI commands we actually need to # Unset PLATFORM_RELATIONSHIPS and PLATFORM_APPLICATION for this script # From 14613959966eb3ee175e72611d0cb417178b9d5b Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 11:02:15 -0500 Subject: [PATCH 034/258] #2836: Fixed bug causing build hook installed composer version to not be loaded correctly for platformsh recipe --- docs/help/2020-changelog.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index bb71f0d99..bcdecb990 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -5,7 +5,8 @@ Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). * Added `6.0` to list of supported `redis` versions -* Fixed bug causing `nvm` installed `node` versions to not load correctly in `platform.sh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) +* Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) +* Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) * Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` From 395f4137875f1ddeb97caff21d1a2d994c0b30c2 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 11:11:26 -0500 Subject: [PATCH 035/258] #2836: Fixed bug causing build hook installed composer version to not be loaded correctly for platformsh recipe part 2 --- plugins/lando-services/scripts/install-composer.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/lando-services/scripts/install-composer.sh b/plugins/lando-services/scripts/install-composer.sh index bf19a2e2a..7009e2446 100644 --- a/plugins/lando-services/scripts/install-composer.sh +++ b/plugins/lando-services/scripts/install-composer.sh @@ -27,7 +27,7 @@ fi # Remove the setup script php -r "unlink('/tmp/composer-setup.php');" -#Check if anything is installed globally +# Check if anything is installed globally if [ -f /var/www/.composer/composer.json ]; then # If this is version 2 then let's make sure hirak/prestissimo is removed if composer --version 2>/dev/null | grep "Composer version 2." > /dev/null; then From 8be6c9e075a31d9d9a4e1a896f1f1161f8ab5647 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 11:26:37 -0500 Subject: [PATCH 036/258] CCI1 --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bd3eb3e12..2d312f375 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,4 +1,4 @@ -version: 2 +version: 2.1 jobs: build: machine: From 6b0ea34e123bec61bc66bb9b641e0ef35590ede3 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 11:34:49 -0500 Subject: [PATCH 037/258] Update docs/guides/lando-phpstorm.md Co-authored-by: Fonata --- docs/guides/lando-phpstorm.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/guides/lando-phpstorm.md b/docs/guides/lando-phpstorm.md index 3e25b12ab..f2ee113c6 100644 --- a/docs/guides/lando-phpstorm.md +++ b/docs/guides/lando-phpstorm.md @@ -14,7 +14,7 @@ and Drupal development. This video tutorial shows you how to set up PhpStorm wit If you’ve a local php installation (for example php 7.1 installed with homebrew on macOS) that listens on port 9000 you may need to change the containers php.ini port specification to another port (i.e. `xdebug.remote_port=9001`) and tell phpstorm to listen on that port. See also [Debugging Drupal 8 with PHPstorm and Lando on your Mac](https://www.isovera.com/blog/debugging-drupal-8-phpstorm-and-lando-your-mac). ### PHP 7.3 and later -With PHP 7.3 the setting `xdebug.remote_port` has been deprecated and instead the setting `xdebug.client_port` should be used. +With PHP 7.3, the setting `xdebug.remote_port` has been deprecated, and the setting `xdebug.client_port` should be used instead. Also the default xdebug port changed from `9000` to `9003`. https://xdebug.org/docs/upgrade_guide#changed-xdebug.remote_port From b375bc3386644cbe4e9f05a8ecfe300035c1429d Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 12:08:33 -0500 Subject: [PATCH 038/258] #2822: Improved error message when platformsh applications cannot be detected --- docs/help/2020-changelog.md | 1 + integrations/lando-platformsh/app.js | 8 +++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index bcdecb990..ef55b5210 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -8,6 +8,7 @@ Lando is **free** and **open source** software that relies on contributions from * Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) * Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) +* Improved error message when `lando` cannot detect any `platformsh` applications [#2822](https://github.com/lando/lando/issues/2822) * Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) diff --git a/integrations/lando-platformsh/app.js b/integrations/lando-platformsh/app.js index 3a8a8ff10..ac660a619 100644 --- a/integrations/lando-platformsh/app.js +++ b/integrations/lando-platformsh/app.js @@ -6,6 +6,7 @@ const fs = require('fs'); const {getLandoServices} = require('./lib/services'); const mkdirp = require('mkdirp'); const open = require('./lib/open'); +const os = require('os'); const path = require('path'); const pshconf = require('./lib/config'); const runconf = require('./lib/run'); @@ -78,7 +79,12 @@ module.exports = (app, lando) => { app.events.on('pre-init', 1, () => { // Error if we don't have at least one .platform.app.yml if (_.isEmpty(app.platformsh.config.applications)) { - lando.log.error(`Could not detect any valid .platform.app.yaml files in ${app.root} or its subdirs!`); + const locations = fs.readdirSync(app.root, {withFileTypes: true}) + .filter(dirent => dirent.isDirectory()) + .map(dirent => ` - ${path.join(app.root, dirent.name, '.platform.app.yaml')}`) + .concat(path.join(app.root, '.platform', 'applications.yaml')) + .join(os.EOL); + lando.log.error(`Could not detect any valid Platform.sh applications in any of: ${os.EOL}${locations}`); } /* From 6b14b79988e58d134995e5544939ca6cab5fa386 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 12:11:39 -0500 Subject: [PATCH 039/258] #2822: Improved error message when platformsh applications cannot be detected part 2 --- integrations/lando-platformsh/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/integrations/lando-platformsh/app.js b/integrations/lando-platformsh/app.js index ac660a619..6ac89aed2 100644 --- a/integrations/lando-platformsh/app.js +++ b/integrations/lando-platformsh/app.js @@ -84,7 +84,7 @@ module.exports = (app, lando) => { .map(dirent => ` - ${path.join(app.root, dirent.name, '.platform.app.yaml')}`) .concat(path.join(app.root, '.platform', 'applications.yaml')) .join(os.EOL); - lando.log.error(`Could not detect any valid Platform.sh applications in any of: ${os.EOL}${locations}`); + lando.log.error(`Could not detect any supported Platform.sh applications in any of: ${os.EOL}${locations}`); } /* From 5d8a1323ae274678ad36705a8aae679c9fcda205 Mon Sep 17 00:00:00 2001 From: Benjamin Bradley Date: Mon, 1 Feb 2021 11:31:41 -0600 Subject: [PATCH 040/258] remove old version links v3.0.0 version links are 2+ years old and no longer relevant --- docs/basics/updating.md | 8 -------- 1 file changed, 8 deletions(-) diff --git a/docs/basics/updating.md b/docs/basics/updating.md index 1cab27506..80f1e11a3 100644 --- a/docs/basics/updating.md +++ b/docs/basics/updating.md @@ -11,11 +11,3 @@ Updating is fairly simple. 3. Follow the normal installation steps with the new version. If you run into any issues after that we recommend you check out this [troubleshooting guide](./../help/updating.md). - -## Caveats - -Lando has tried to maintain backwards compatibility as best as possible on it's road to a stable `3.0.0` release. However it has introduced breaking changes in a few Lando version. For these versions you will likely want to [uninstall](./uninstalling.md) and consult the relevant release notes for the breaking versions. - -* [3.0.0-rc.2](https://github.com/lando/lando/releases/tag/v3.0.0-rc.2) -* [3.0.0-rc.1](https://github.com/lando/lando/releases/tag/v3.0.0-rc.1) -* [3.0.0-beta.41](https://github.com/lando/lando/releases/tag/v3.0.0-beta.41) From 3da9925a5565216bc44d4532501f6b86f756a472 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 13:05:08 -0500 Subject: [PATCH 041/258] #2818: Improved error message when lagoon.yml cannot be detected --- docs/help/2020-changelog.md | 3 ++- integrations/lando-lagoon/app.js | 3 ++- integrations/lando-lagoon/lib/config.js | 5 +++++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index ef55b5210..a4159d790 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -8,7 +8,8 @@ Lando is **free** and **open source** software that relies on contributions from * Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) * Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) -* Improved error message when `lando` cannot detect any `platformsh` applications [#2822](https://github.com/lando/lando/issues/2822) +* Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) +* Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) * Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) diff --git a/integrations/lando-lagoon/app.js b/integrations/lando-lagoon/app.js index 5d6087ee3..4f2c07585 100644 --- a/integrations/lando-lagoon/app.js +++ b/integrations/lando-lagoon/app.js @@ -68,7 +68,8 @@ module.exports = (app, lando) => { app.events.on('pre-init', 1, () => { // Error if we don't have at least one docker service or any lagoon config if (_.isEmpty(app.lagoon.containers) || _.isEmpty(app.lagoon.config.lagoon)) { - lando.log.error('Could not detect a valid lagoon setup in %s', app.root); + throw Error(`The lagoon recipe requires a lagoon.yml in ${app.root} but we couldn't find one! ` + + `Check out https://docs.lando.dev/config/lagoon.html to see how all the magic works!`); } // Get the raw lagoon config diff --git a/integrations/lando-lagoon/lib/config.js b/integrations/lando-lagoon/lib/config.js index 3e3fdf989..1bc0ee5b2 100644 --- a/integrations/lando-lagoon/lib/config.js +++ b/integrations/lando-lagoon/lib/config.js @@ -12,6 +12,11 @@ const yaml = require('js-yaml'); exports.loadConfigFiles = baseDir => { // Get the lagoon file const lagoonFile = path.join(baseDir, '.lagoon.yml'); + + // If we don't have a lagoonfile then immediately return + if (!fs.existsSync(lagoonFile)) return {}; + + // Otherwise STILL OK TO GO const lagoonConfig = yaml.safeLoad(fs.readFileSync(lagoonFile)); // Use that to get the docker-compose file const composeFile = path.join(baseDir, lagoonConfig['docker-compose-yaml']); From 5fee2f3b7ad92af9622aede29913d7dd16afde00 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 13:46:23 -0500 Subject: [PATCH 042/258] #2828: Add support for lagoon.type === none --- docs/config/lagoon.md | 2 ++ docs/help/2020-changelog.md | 1 + integrations/lando-lagoon/lib/config.js | 12 +++++++++- integrations/lando-lagoon/lib/services.js | 1 + .../services/lagoon-none/builder.js | 22 +++++++++++++++++++ 5 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 integrations/lando-lagoon/services/lagoon-none/builder.js diff --git a/docs/config/lagoon.md b/docs/config/lagoon.md index 75b99b21a..b9a5b92f9 100644 --- a/docs/config/lagoon.md +++ b/docs/config/lagoon.md @@ -98,6 +98,8 @@ services: For the most up to date list of supported labels, check out [this](https://github.com/lando/lando/blob/master/integrations/lando-lagoon/lib/services.js#L15). To see labels in action check out the official [Amazee.io Drupal 9 Lagoon example](https://github.com/amazeeio/drupal-example-simple/blob/9.x/docker-compose.yml#L40). +Also note that Lando additionally supports `lagoon.type === none` as documented over [here](https://docs.lagoon.sh/lagoon/using-lagoon-the-basics/docker-compose-yml#skip-ignore-containers). + ### Build steps If you have steps you need to run to get your site into a workable place you can put them in the `build` key of your recipes `config`. By default, we will run `composer install` but you may wish to augment that with any front end compilation tasks you may have as in the example below: diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index a4159d790..b8d57b770 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -4,6 +4,7 @@ Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). +* Added support for `lagoon.type == none` [#2828](https://github.com/lando/lando/issues/2828) * Added `6.0` to list of supported `redis` versions * Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) * Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) diff --git a/integrations/lando-lagoon/lib/config.js b/integrations/lando-lagoon/lib/config.js index 1bc0ee5b2..66021ae11 100644 --- a/integrations/lando-lagoon/lib/config.js +++ b/integrations/lando-lagoon/lib/config.js @@ -6,6 +6,16 @@ const fs = require('fs'); const path = require('path'); const yaml = require('js-yaml'); + +/* + * Helper to get label + */ +const getLabel = labels => { + if (_.has(labels, 'lando.type')) return _.get(labels, 'lando.type'); + else if (_.get(labels, 'lagoon.type') === 'none') return 'none'; + else return; +}; + /* * Helper to load all the lagoon config files we can find */ @@ -36,7 +46,7 @@ exports.parseServices = (services, recipeConfig) => _(services) // Remove unneeded things from the docker config and determine the type of the service .map((config, name) => _.merge({}, { name, - type: _.get(config.labels, 'lando.type'), + type: getLabel(config.labels), compose: _.omit(config, ['volumes', 'volumes_from', 'networks', 'user']), config: recipeConfig, })) diff --git a/integrations/lando-lagoon/lib/services.js b/integrations/lando-lagoon/lib/services.js index 8d060c311..1e64533f9 100644 --- a/integrations/lando-lagoon/lib/services.js +++ b/integrations/lando-lagoon/lib/services.js @@ -16,6 +16,7 @@ const getLandoServiceType = type => { switch (type) { case 'nginx': return 'lagoon-nginx'; case 'nginx-drupal': return 'lagoon-nginx'; + case 'none': return 'lagoon-none'; case 'mariadb': return 'lagoon-mariadb'; case 'mariadb-drupal': return 'lagoon-mariadb'; case 'php-cli': return 'lagoon-php-cli'; diff --git a/integrations/lando-lagoon/services/lagoon-none/builder.js b/integrations/lando-lagoon/services/lagoon-none/builder.js new file mode 100644 index 000000000..850853476 --- /dev/null +++ b/integrations/lando-lagoon/services/lagoon-none/builder.js @@ -0,0 +1,22 @@ +'use strict'; + +// Modules +const _ = require('lodash'); + +// Builder +module.exports = { + name: 'lagoon-none', + config: { + version: 'custom', + confSrc: __dirname, + }, + parent: '_compose', + builder: (parent, config) => class LandoLagoonNone extends parent { + constructor(id, options = {}, factory) { + // Merge + options = _.merge({}, config, options); + // Add in the php service and push downstream + super(id, options, {services: _.set({}, options.name, options.lagoon)}); + }; + }, +}; From f95c569dd7db49fb61b021cc8edb5648c71278bd Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 16:03:16 -0500 Subject: [PATCH 043/258] #2762: Dumbed down new lagoon pull file logix for now --- docs/help/2020-changelog.md | 1 + integrations/lando-lagoon/scripts/lagoon-pull.sh | 12 ++++-------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index b8d57b770..2b4ae162b 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -9,6 +9,7 @@ Lando is **free** and **open source** software that relies on contributions from * Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) * Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) +* Improved `lando pull` for `lagoon` recipes to handle other files directory locations [#2762](https://github.com/lando/lando/issues/2762) * Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) * Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) * Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` diff --git a/integrations/lando-lagoon/scripts/lagoon-pull.sh b/integrations/lando-lagoon/scripts/lagoon-pull.sh index 44655c795..b36c08c77 100755 --- a/integrations/lando-lagoon/scripts/lagoon-pull.sh +++ b/integrations/lando-lagoon/scripts/lagoon-pull.sh @@ -165,16 +165,12 @@ if [ "${LANDO_FILES_ALIAS}" != "lagoon.${LANDO_LAGOON_PROJECT}-none" ]; then lando_red "Files alias @${LANDO_FILES_ALIAS} access failed!" exit 1 fi - lando_green "Files alias @${LANDO_FILES_ALIAS} access confirmed!" - if ! drush "@${LANDO_FILES_ALIAS}" status | grep -q "File directory path"; then - lando_red "Unable to pull files from ${LANDO_FILES_ALIAS} without a file directory path specified. Set up or import a database first." - exit 1 - else - DRUPAL_FILES_PATH=$(drush @${LANDO_FILES_ALIAS} dd files | tr -d '\n' 2>/dev/null) - fi - + # Get the files path + # NOTE: It may not be safe to assume this "goes well" under all conditions eg does something + # helpful when it fails but lets wait until we know more before we do anything else + DRUPAL_FILES_PATH=$(drush @${LANDO_FILES_ALIAS} dd files | tr -d '\n' 2>/dev/null) lando_pink "Attemping to sync files to/from directory: ${DRUPAL_FILES_PATH}" # Import files with rsync From d5d669aaedc7268ad8b6993f2f62fe6a5c026d66 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 16:15:41 -0500 Subject: [PATCH 044/258] #2762: Dumbed down new lagoon pull file logix for now part 2 --- plugins/lando-core/compose/lando/builder.js | 1 - 1 file changed, 1 deletion(-) diff --git a/plugins/lando-core/compose/lando/builder.js b/plugins/lando-core/compose/lando/builder.js index 673535301..8d84f9a3b 100644 --- a/plugins/lando-core/compose/lando/builder.js +++ b/plugins/lando-core/compose/lando/builder.js @@ -11,7 +11,6 @@ const utils = require('./../../lib/utils'); /* * The lowest level lando service, this is where a lot of the deep magic lives - * @TODO */ module.exports = { name: '_lando', From f73ca966a3fdabf0683a305638a944049b588fe1 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 16:16:56 -0500 Subject: [PATCH 045/258] #2762: Dumbed down new lagoon pull file logix for now part 3 --- .circleci/config.yml | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2d312f375..96c60864d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -7,24 +7,6 @@ jobs: parallelism: 10 steps: - checkout - - run: - name: Assess needs or bail - command: | - # Extract commit range (or single commit) - COMMIT_RANGE=$(echo "${CIRCLE_COMPARE_URL}" | cut -d/ -f7) - # Fix single commit, unfortunately we don't always get a commit range from Circle CI - if [[ $COMMIT_RANGE != *"..."* ]]; then - COMMIT_RANGE="${COMMIT_RANGE}...${COMMIT_RANGE}" - fi - # Print some helpful things - echo "Operating on commit range: $COMMIT_RANGE" - # Check if we need to run tests and bail if we don't - LANDO_CHANGED_FILES=$(git diff --name-only $COMMIT_RANGE | cat) - echo "The following files have changed: $LANDO_CHANGED_FILES" - LANDO_NEEDS_TESTS=$(echo $LANDO_CHANGED_FILES | grep -e .circleci -e bin/ -e lib/ -e plugins/ -e integrations/ -e examples/ -e tests/ &>/dev/null && echo true || echo false) - if [[ "$LANDO_NEEDS_TESTS" == "false" ]]; then - circleci-agent step halt - fi - restore_cache: keys: - yarn-packages-v1-{{ .Branch }}-{{ checksum "yarn.lock" }} From 94216428e1c2a93819d5f4a58fdc9f8e8bd7c6f9 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 18:12:11 -0500 Subject: [PATCH 046/258] #2833: Fix busted switch to wkhtmltopdf 0.12.5, update to terminus 2.5.0 --- docs/help/2020-changelog.md | 3 ++- .../lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile | 2 +- .../lando-pantheon/recipes/pantheon/5.3-fpm/README.md | 2 +- .../lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile | 4 ++-- .../lando-pantheon/recipes/pantheon/5.5-fpm/README.md | 4 ++-- .../lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile | 9 ++++++--- .../lando-pantheon/recipes/pantheon/5.6-fpm/README.md | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.0-fpm/README.md | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.1-fpm/README.md | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.2-fpm/README.md | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.3-fpm/README.md | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile | 9 ++++++--- .../lando-pantheon/recipes/pantheon/7.4-fpm/README.md | 9 ++++++--- 17 files changed, 80 insertions(+), 43 deletions(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index 2b4ae162b..4ac96474d 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -12,7 +12,8 @@ Lando is **free** and **open source** software that relies on contributions from * Improved `lando pull` for `lagoon` recipes to handle other files directory locations [#2762](https://github.com/lando/lando/issues/2762) * Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) * Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) -* Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` +* Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` in recent (eg not EOL) `php` images +* Updated `pantheon` recipe to use `terminus` version `2.5.0` ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) diff --git a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile index 04ce5aed7..9f6aea8d4 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/Dockerfile @@ -5,7 +5,7 @@ FROM devwithlando/php:5.3-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.5 +ENV WKHTMLTOPDF_VERSION 0.12.2 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV MAVEN_VERSION 3.5.4 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md index fe5c4f60e..c07aa29e0 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.3-fpm/README.md @@ -11,7 +11,7 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:5.3-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.5 +ENV WKHTMLTOPDF_VERSION 0.12.2 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 ENV MAVEN_VERSION 3.5.4 diff --git a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile index 77a8a5b01..f4ea1e755 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/Dockerfile @@ -5,10 +5,10 @@ FROM devwithlando/php:5.5-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.5 +ENV WKHTMLTOPDF_VERSION 0.12.2 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon diff --git a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md index 0cb514314..8dc677c1d 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.5-fpm/README.md @@ -11,10 +11,10 @@ A container that approximates the appserver used on Pantheon. FROM devwithlando/php:5.5-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.5 +ENV WKHTMLTOPDF_VERSION 0.12.2 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon diff --git a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile index 9ee790b78..c8eab1f15 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile @@ -8,7 +8,7 @@ FROM devwithlando/php:5.6-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon @@ -25,8 +25,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md index b78074f14..8a5dda58a 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md @@ -14,7 +14,7 @@ FROM devwithlando/php:5.6-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon @@ -31,8 +31,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile index fb29f3723..8a12c226c 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile @@ -8,7 +8,7 @@ FROM devwithlando/php:7.0-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon @@ -25,8 +25,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md index 1b967c337..a8258ca85 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md @@ -14,7 +14,7 @@ FROM devwithlando/php:7.0-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon @@ -31,8 +31,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile index 3f9b72c27..60cab93e1 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile @@ -8,7 +8,7 @@ FROM devwithlando/php:7.1-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon @@ -25,8 +25,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md index 6de5d9bb8..a0ca026c5 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md @@ -14,7 +14,7 @@ FROM devwithlando/php:7.1-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 # Install the additional things that make the pantheon @@ -31,8 +31,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile index 930481819..6c5370fcf 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile @@ -8,7 +8,7 @@ FROM devwithlando/php:7.2-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 ENV TIKA_VERSION 1.18 @@ -26,8 +26,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md index 7f094672d..72c49ffe1 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md @@ -14,7 +14,7 @@ FROM devwithlando/php:7.2-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 ENV TIKA_VERSION 1.18 @@ -32,8 +32,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile index d6e96825f..644701aa4 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile @@ -8,7 +8,7 @@ FROM devwithlando/php:7.3-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 ENV TIKA_VERSION 1.18 @@ -26,8 +26,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md index 1784b1ff4..4218585c3 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md @@ -14,7 +14,7 @@ FROM devwithlando/php:7.3-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 ENV TIKA_VERSION 1.18 @@ -32,8 +32,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile index a75bb75e6..680da2a5d 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/Dockerfile @@ -8,7 +8,7 @@ FROM devwithlando/php:7.4-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 ENV TIKA_VERSION 1.18 @@ -26,8 +26,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.buster_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.buster_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.buster_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md index 3f7759afb..0b7eb1fd1 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.4-fpm/README.md @@ -14,7 +14,7 @@ FROM devwithlando/php:7.4-fpm-2 ENV WKHTMLTOPDF_VERSION 0.12.5 ENV PHANTOMJS_VERSION 2.1.1 ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.4.1 +ENV LANDO_TERMINUS_VERSION 2.5.0 ENV MAVEN_VERSION 3.5.4 ENV TIKA_VERSION 1.18 @@ -32,8 +32,11 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && curl -OL "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" \ - && tar xJfv "wkhtmltox-${WKHTMLTOPDF_VERSION}_linux-generic-amd64.tar.xz" && cp -rf /tmp/wkhtmltox/bin/* /srv/bin \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.buster_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.buster_amd64.deb" \ + && apt-get install -yf \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.buster_amd64.deb" \ + && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ && mv phantomjs-${PHANTOMJS_VERSION}-linux-x86_64/bin/phantomjs /srv/bin/phantomjs-${PHANTOMJS_VERSION} \ From 29134796de401f8d4ce779674b5194f7dbf412ae Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 18:13:40 -0500 Subject: [PATCH 047/258] #2833: Fix busted switch to wkhtmltopdf 0.12.5, update to terminus 2.5.0 part 2 --- docs/help/2020-changelog.md | 2 +- .../lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile | 6 +++--- .../lando-pantheon/recipes/pantheon/5.6-fpm/README.md | 6 +++--- .../lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile | 6 +++--- .../lando-pantheon/recipes/pantheon/7.0-fpm/README.md | 6 +++--- .../lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile | 6 +++--- .../lando-pantheon/recipes/pantheon/7.1-fpm/README.md | 6 +++--- .../lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile | 6 +++--- .../lando-pantheon/recipes/pantheon/7.2-fpm/README.md | 6 +++--- .../lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile | 6 +++--- .../lando-pantheon/recipes/pantheon/7.3-fpm/README.md | 6 +++--- 11 files changed, 31 insertions(+), 31 deletions(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index 4ac96474d..78ceed1e4 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -12,7 +12,7 @@ Lando is **free** and **open source** software that relies on contributions from * Improved `lando pull` for `lagoon` recipes to handle other files directory locations [#2762](https://github.com/lando/lando/issues/2762) * Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) * Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) -* Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` in recent (eg not EOL) `php` images +* Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` in _most_ `php` images * Updated `pantheon` recipe to use `terminus` version `2.5.0` ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) diff --git a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile index c8eab1f15..84ac13f7b 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/Dockerfile @@ -25,10 +25,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md index 8a5dda58a..86324a2bb 100644 --- a/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/5.6-fpm/README.md @@ -31,10 +31,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile index 8a12c226c..8df1c1a20 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/Dockerfile @@ -25,10 +25,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md index a8258ca85..44b50e934 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.0-fpm/README.md @@ -31,10 +31,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile index 60cab93e1..6708abb28 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/Dockerfile @@ -25,10 +25,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md index a0ca026c5..4d02c59c8 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.1-fpm/README.md @@ -31,10 +31,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile index 6c5370fcf..513f0ba7a 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/Dockerfile @@ -26,10 +26,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md index 72c49ffe1..b90db8914 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.2-fpm/README.md @@ -32,10 +32,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile index 644701aa4..f63a00779 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile +++ b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/Dockerfile @@ -26,10 +26,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ diff --git a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md index 4218585c3..5ce313e7a 100644 --- a/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md +++ b/integrations/lando-pantheon/recipes/pantheon/7.3-fpm/README.md @@ -32,10 +32,10 @@ RUN mkdir -p /usr/share/man/man1 \ && chown -R www-data:www-data /var/www /srv/bin \ && wget "https://github.com/pantheon-systems/terminus/releases/download/${LANDO_TERMINUS_VERSION}/terminus.phar" -O /usr/local/bin/terminus \ && chmod +x /usr/local/bin/terminus \ - && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ - && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && cd /tmp && wget "https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/${WKHTMLTOPDF_VERSION}/wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ + && dpkg -i "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && apt-get install -yf \ - && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.strech_amd64.deb" \ + && rm -rf "wkhtmltox_${WKHTMLTOPDF_VERSION}-1.stretch_amd64.deb" \ && ln -sf /usr/local/bin/wkhtmltopdf /srv/bin/wkhtmltopdf \ && cd /srv/bin \ && curl -fsSL "https://github.com/Medium/phantomjs/releases/download/v${PHANTOMJS_VERSION}/phantomjs-${PHANTOMJS_VERSION}-linux-x86_64.tar.bz2" | tar -xjv \ From f39eaf69701bc0687b5da14065eaec0ad5d91631 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 20:33:41 -0500 Subject: [PATCH 048/258] Fixed bug causing custom port to not be passed in correctly for lagoon auth endpoint --- docs/help/2020-changelog.md | 1 + integrations/lando-lagoon/lib/api.js | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index 78ceed1e4..1179ca117 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -9,6 +9,7 @@ Lando is **free** and **open source** software that relies on contributions from * Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) * Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) +* Fixed bug causing `port` to not be passed in correctly when authing against custom `lagoon` instance * Improved `lando pull` for `lagoon` recipes to handle other files directory locations [#2762](https://github.com/lando/lando/issues/2762) * Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) * Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) diff --git a/integrations/lando-lagoon/lib/api.js b/integrations/lando-lagoon/lib/api.js index 19b0a745c..a5e0318ae 100644 --- a/integrations/lando-lagoon/lib/api.js +++ b/integrations/lando-lagoon/lib/api.js @@ -51,7 +51,7 @@ module.exports = class LagoonApi { const {keyPath, host, port} = keys.parseKey(key); this.key = keyPath; this.host = host; - this.post = port; + this.port = port; this.lando = lando; this.log = lando.log; @@ -66,9 +66,9 @@ module.exports = class LagoonApi { }; auth() { - this.log.verbose('Fetching token from %s using %s', this.sshURL, this.key); + this.log.verbose('Fetching token from %s:%s using %s', this.sshURL, this.port, this.key); return Promise.retry(() => { - return utils.run(this.lando, `/helpers/lagoon-auth.sh ${this.sshURL}`, this.key) + return utils.run(this.lando, `/helpers/lagoon-auth.sh ${this.sshURL} lagoon ${this.port}`, this.key) .then(token => { this.axios.defaults.headers.common = {'Authorization': `Bearer ${_.trim(token)}`}; }) From 8ff4cb2534e3dac6bb4ab808aa90a48416cd98d8 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 21:42:10 -0500 Subject: [PATCH 049/258] #2831: Added dumb support for the drupal9 pantheon framework --- docs/help/2020-changelog.md | 1 + integrations/lando-pantheon/lib/utils.js | 1 + .../recipes/pantheon/builder.js | 3 +- .../recipes/pantheon/drupal9.conf.tpl | 210 ++++++++++++++++++ .../recipes/pantheon/prepend.php | 2 +- 5 files changed, 215 insertions(+), 2 deletions(-) create mode 100644 integrations/lando-pantheon/recipes/pantheon/drupal9.conf.tpl diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index 1179ca117..ad9b2b524 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -6,6 +6,7 @@ Lando is **free** and **open source** software that relies on contributions from * Added support for `lagoon.type == none` [#2828](https://github.com/lando/lando/issues/2828) * Added `6.0` to list of supported `redis` versions +* Added "dumb" support for the `drupal9` `pantheon` framework [#2831](https://github.com/lando/lando/issues/2831) * Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) * Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) * Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) diff --git a/integrations/lando-pantheon/lib/utils.js b/integrations/lando-pantheon/lib/utils.js index caeaf2d46..bc005e5d4 100644 --- a/integrations/lando-pantheon/lib/utils.js +++ b/integrations/lando-pantheon/lib/utils.js @@ -66,6 +66,7 @@ const getFilemount = framework => { case 'backdrop': return 'files'; case 'drupal': return 'sites/default/files'; case 'drupal8': return 'sites/default/files'; + case 'drupal9': return 'sites/default/files'; case 'wordpress': case 'wordpress_network': return 'wp-content/uploads'; diff --git a/integrations/lando-pantheon/recipes/pantheon/builder.js b/integrations/lando-pantheon/recipes/pantheon/builder.js index 2510616da..702fb7f56 100644 --- a/integrations/lando-pantheon/recipes/pantheon/builder.js +++ b/integrations/lando-pantheon/recipes/pantheon/builder.js @@ -107,7 +107,8 @@ module.exports = { // Enforce certain options for pantheon parity options.via = 'nginx:1.16'; - options.database = 'mariadb:10.1'; + options.database = (options.framework === 'drupal9') ? 'mariadb:10.4': 'mariadb:10.1' + // Set correct things based on framework options.defaultFiles.vhosts = `${options.framework}.conf.tpl`; options = overrideAppserver(options); diff --git a/integrations/lando-pantheon/recipes/pantheon/drupal9.conf.tpl b/integrations/lando-pantheon/recipes/pantheon/drupal9.conf.tpl new file mode 100644 index 000000000..1211ef37a --- /dev/null +++ b/integrations/lando-pantheon/recipes/pantheon/drupal9.conf.tpl @@ -0,0 +1,210 @@ +# We use $http_user_agent_https to determine if the request arrived at the platform +# as an http or an https request. Capture that here for use later. $client_scheme +# will be appropriately set to either http or https. +map $http_user_agent_https $client_scheme { + default $scheme; + ON https; + OFF http; +} + +server { + listen 80 default_server; + listen 443 ssl; + server_name localhost; + + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + + root "{{LANDO_WEBROOT}}"; + index index.php index.html index.htm; + port_in_redirect off; + + client_max_body_size 100M; + + gzip on; + gzip_proxied any; + gzip_types text/plain text/html text/css application/x-javascript application/json text/xml application/xml application/xml+rss text/javascript application/x-font-ttf font/opentype application/vnd.ms-fontobject image/svg+xml; + gzip_vary on; + gzip_http_version 1.0; + + ssl_certificate /certs/cert.crt; + ssl_certificate_key /certs/cert.key; + ssl_verify_client off; + keepalive_timeout 70; + + # No reading git files + location ~ /\.git { + deny all; + } + + # Original formula Drupal code protection as per .htaccess + location ~ \.(engine|inc|info|install|make|module|profile|test|po|sh|.*sql|theme|tpl(\.php)?|xtmpl)(~|\.sw[op]|\.bak|\.orig|\.save)?$|^(\..*|Entries.*|Repository|Root|Tag|Template|composer\.(json|lock))$|^#.*#$|\.php(~|\.sw[op]|\.bak|\.orig\.save)$ { + # Go straight to @cleanurl without 'try_files' or php execution + try_files pantheon_blocked_file.html @cleanurl; + } + + # Protect /private (for private code) + location ~ ^/private/ { + return 403; + } + # Protect /sites/default/files/private (for private files) + location ~ ^/sites/default/files/private/ { + return 403; + } + # Protect the pantheon.yml file (Quicksilver / platform configuration) + location ~ ^/pantheon.yml$ { + return 403; + } + # Protect /sites/default/config (for staging configuration) + location ~ ^/sites/default/config/ { + return 403; + } + # Protect /sites/default/files/config (for active configuration) + location ~ ^/sites/default/files/config/ { + return 403; + } + location ~ /sites/default/files/.*\.php$ { + return 403; + } + location ~ ^/robots.txt { + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + add_header Cache-Control max-age=86000; + root /srv/error_pages; + } + + # Web fonts support. + location ~* \.(eot|ttf|woff|woff2|otf|svg)$ { + auth_basic $auth_basic_realm; + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + add_header Access-Control-Allow-Origin *; # Firefox needs this. + + try_files $uri $uri/ /index.php?$args; + + + expires -1; + log_not_found off; + } + + # Support for .svgz + location ~* \.(svgz)$ { + auth_basic $auth_basic_realm; + + try_files $uri $uri/ /index.php?$args; + + expires -1; + + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + add_header Content-encoding gzip; # So browsers will gunzip + + gzip off; # don't double-compress + } + + # Set the expiration for assets to 1 day, except in dev. + # This could be done with an 'if' in the '/' location, but the + # http://wiki.nginx.org/IfIsEvil page is scary. + location ~ \.(js|JS|css|CSS|png|PNG|igs|IGS|iges|IGES|jpg|JPG|jpeg|JPEG|gif|GIF|ico|ICO|txt|TXT|xml)$ { + auth_basic $auth_basic_realm; + + try_files $uri $uri/ /index.php?$args; + + expires -1; + log_not_found off; + } + + location / { + auth_basic $auth_basic_realm; + # @drupal is true for d6, d7 and d8. We want to use @cleanurl for d6 and d7. + try_files $uri $uri/ /index.php?$args; + # Catch directory listing errors (i.e. no code) + error_page 403 =561 /403.html; + error_page 301 =301 $client_scheme://$host$uri/$is_args$args; + } + + location @cleanurl { + rewrite ^/(.*)$ /index.php?q=$1 last; + } + + # Block any php file in the 'vendor' directory + # n.b. In order for this to be secure, it must match the allowed + # fastcgi_locations locations defined in _appserver_bindings.rb. + # Currently, '\.php$' is the only on that overlaps with '^/vendor/'. + location ~ ^/vendor/.* { + # Go straight to @cleanurl without 'try_files' or php execution + try_files pantheon_blocked_file.html /index.php?$args; + } + + + # These need to be listed from most specific to most general. + location ~ ^/simplesaml/ { + auth_basic $auth_basic_realm; + + # There could be several add_header directives. These directives are inherited from the previous level if and only if there are no add_header directives defined on the current level. + # As per: http://nginx.org/en/docs/http/ngx_http_headers_module.html + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + add_header X-Pantheon-Phpreq yes always; + + fastcgi_intercept_errors on; + fastcgi_pass fpm:9000; + fastcgi_index index.php; + include fastcgi_params; + # Allow SimpleSamlPHP to work by settig PATH_INFO, etc + fastcgi_split_path_info ^(.+?\.php)(|/.*)$; + fastcgi_param SCRIPT_FILENAME "{{LANDO_WEBROOT}}$fastcgi_script_name"; + # Catch php-fpm timeout errors + error_page 504 /504.html; + } + location ~ ^/update.php|authorize.php { + auth_basic $auth_basic_realm; + + # There could be several add_header directives. These directives are inherited from the previous level if and only if there are no add_header directives defined on the current level. + # As per: http://nginx.org/en/docs/http/ngx_http_headers_module.html + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + add_header X-Pantheon-Phpreq yes always; + + # Content-Type: text/html; charset=UTF-8 + fastcgi_param PHP_VALUE "default_mimetype=\"text/html\" +default_charset=\"UTF-8\""; + fastcgi_intercept_errors on; + fastcgi_pass fpm:9000; + fastcgi_index index.php; + include fastcgi_params; + # Allow SimpleSamlPHP to work by settig PATH_INFO, etc + fastcgi_split_path_info ^(.+?\.php)(|/.*)$; + fastcgi_param SCRIPT_FILENAME "{{LANDO_WEBROOT}}$fastcgi_script_name"; + # Catch php-fpm timeout errors + error_page 504 /504.html; + } + location ~ \.php$ { + auth_basic $auth_basic_realm; + + # There could be several add_header directives. These directives are inherited from the previous level if and only if there are no add_header directives defined on the current level. + # As per: http://nginx.org/en/docs/http/ngx_http_headers_module.html + add_header X-Pantheon-Site TBD always; + add_header X-Pantheon-Environment lando always; + add_header X-Pantheon-Phpreq yes always; + + try_files $uri $uri/ /index.php?$args; + # Content-Type: text/html; charset=UTF-8 + fastcgi_param PHP_VALUE "default_mimetype=\"text/html\" +default_charset=\"UTF-8\""; + fastcgi_intercept_errors on; + fastcgi_pass fpm:9000; + fastcgi_index index.php; + include fastcgi_params; + # Allow SimpleSamlPHP to work by settig PATH_INFO, etc + fastcgi_split_path_info ^(.+?\.php)(|/.*)$; + fastcgi_param SCRIPT_FILENAME "{{LANDO_WEBROOT}}$fastcgi_script_name"; + # Catch php-fpm timeout errors + error_page 504 /504.html; + } + + location ~ /\.ht { + deny all; + } + +} diff --git a/integrations/lando-pantheon/recipes/pantheon/prepend.php b/integrations/lando-pantheon/recipes/pantheon/prepend.php index cf658a952..93195b83a 100644 --- a/integrations/lando-pantheon/recipes/pantheon/prepend.php +++ b/integrations/lando-pantheon/recipes/pantheon/prepend.php @@ -64,7 +64,7 @@ */ if ( isset($_ENV['FRAMEWORK']) && - $_ENV['FRAMEWORK'] == 'drupal8' && + ($_ENV['FRAMEWORK'] == 'drupal8' || $_ENV['FRAMEWORK'] == 'drupal9') && (empty($GLOBALS['install_state'])) && php_sapi_name() != "cli" ) { From b759b1bf86e49cb5a8f0029a44ffb4031feef6bf Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 21:55:59 -0500 Subject: [PATCH 050/258] Updated to Docker Desktop 3.1.0 --- .circleci/lando.yml | 2 +- config.yml | 2 +- docs/help/2020-changelog.md | 1 + scripts/build-darwin.sh | 4 ++-- scripts/build-win32.ps1 | 4 ++-- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.circleci/lando.yml b/.circleci/lando.yml index ccd357546..86df05bda 100644 --- a/.circleci/lando.yml +++ b/.circleci/lando.yml @@ -11,7 +11,7 @@ dockerSupportedVersions: linux: https://docs.docker.com/compose/install/#install-compose-on-linux-systems desktop: min: "2.1.0.0" - max: "3.0.1" + max: "3.1.99" link: darwin: https://docs.docker.com/docker-for-mac/release-notes/ win32: https://docs.docker.com/docker-for-windows/release-notes/ diff --git a/config.yml b/config.yml index 8b66ddf86..bb21dd820 100644 --- a/config.yml +++ b/config.yml @@ -11,7 +11,7 @@ dockerSupportedVersions: linux: https://docs.docker.com/compose/install/#install-compose-on-linux-systems desktop: min: "2.1.0.0" - max: "3.0.1" + max: "3.1.99" link: darwin: https://docs.docker.com/docker-for-mac/release-notes/ win32: https://docs.docker.com/docker-for-windows/release-notes/ diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index ad9b2b524..b05a07d52 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -16,6 +16,7 @@ Lando is **free** and **open source** software that relies on contributions from * Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) * Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` in _most_ `php` images * Updated `pantheon` recipe to use `terminus` version `2.5.0` +* Updated to Docker Desktop `3.1.0` and provided wider future patch support because https://github.com/docker/roadmap/issues/183 ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) diff --git a/scripts/build-darwin.sh b/scripts/build-darwin.sh index 9b4ac4422..bce4afe84 100755 --- a/scripts/build-darwin.sh +++ b/scripts/build-darwin.sh @@ -10,8 +10,8 @@ LANDO_VERSION=$(node -pe 'JSON.parse(process.argv[1]).version' "$(cat package.js LANDO="lando.txt" # Docker -DOCKER_VERSION="3.0.1" -DOCKER_DOWNLOAD="50773" +DOCKER_VERSION="3.1.0" +DOCKER_DOWNLOAD="51484" # Certs TEAM_ID="FY8GAUX282" diff --git a/scripts/build-win32.ps1 b/scripts/build-win32.ps1 index b80e828ad..fa69b8d1d 100644 --- a/scripts/build-win32.ps1 +++ b/scripts/build-win32.ps1 @@ -10,8 +10,8 @@ $ErrorActionPreference = "Stop" # Lando version information $lando_pkg = Get-Content "package.json" | Out-String | ConvertFrom-Json $lando_version = $lando_pkg.version -$docker_version = "3.0.0" -$docker_build = "50684" +$docker_version = "3.1.0" +$docker_build = "51484" # Get some ENV things $temp_dir = $env:TMP From fde3994cabc43aaad82d32ec22f6a1c2406aaa68 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Mon, 1 Feb 2021 22:17:53 -0500 Subject: [PATCH 051/258] Updated to Docker Desktop 3.1.0 part 2 --- integrations/lando-pantheon/recipes/pantheon/builder.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/integrations/lando-pantheon/recipes/pantheon/builder.js b/integrations/lando-pantheon/recipes/pantheon/builder.js index 702fb7f56..c9fd44318 100644 --- a/integrations/lando-pantheon/recipes/pantheon/builder.js +++ b/integrations/lando-pantheon/recipes/pantheon/builder.js @@ -107,7 +107,7 @@ module.exports = { // Enforce certain options for pantheon parity options.via = 'nginx:1.16'; - options.database = (options.framework === 'drupal9') ? 'mariadb:10.4': 'mariadb:10.1' + options.database = (options.framework === 'drupal9') ? 'mariadb:10.4': 'mariadb:10.1'; // Set correct things based on framework options.defaultFiles.vhosts = `${options.framework}.conf.tpl`; From 0b5f4a0c9f8a7dcdd4a7459cabd3249f92e96dc9 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 08:22:46 -0500 Subject: [PATCH 052/258] release v3.0.25 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 1079bc662..8a8c5ebb2 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "lando", "description": "The best local development solution in the galaxy.", "license": "GPL-3.0", - "version": "3.0.24", + "version": "3.0.25", "repository": { "type": "git", "url": "https://github.com/lando/lando" From b4de5f601284c99e51f479abd92c2d08d09c1bf3 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 08:23:32 -0500 Subject: [PATCH 053/258] Update changelog --- docs/help/2020-changelog.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index b05a07d52..bae4227ae 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -1,6 +1,6 @@ # 2020 -## v3.0.25 - In development +## v3.0.25 - [February 2, 2020](https://github.com/lando/lando/releases/tag/v3.0.25) Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). From b52cd99862dc766202c184ead035517fb573bb65 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 10:02:21 -0500 Subject: [PATCH 054/258] Attempt BIONIC based build --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 5cb31b5bc..ef907fd9b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,6 @@ language: node_js node_js: 12 -dist: xenial +dist: bionic cache: yarn: true directories: From d77d9d96a045d01dd12d9db77d8d359ffc458d8d Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 10:18:39 -0500 Subject: [PATCH 055/258] Skip pacman builds for now: --- scripts/build-linux.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/build-linux.sh b/scripts/build-linux.sh index 1ad73b890..c07a97f8b 100755 --- a/scripts/build-linux.sh +++ b/scripts/build-linux.sh @@ -48,5 +48,5 @@ cd .. && mkdir -p dist # Build our three packages cd ../.. ./scripts/build-pkg.sh deb $LANDO_VERSION -./scripts/build-pkg.sh pacman $LANDO_VERSION +# ./scripts/build-pkg.sh pacman $LANDO_VERSION ./scripts/build-pkg.sh rpm $LANDO_VERSION From a55e9e850187fed3b2c7c428d704f9f68727c5e3 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 10:29:04 -0500 Subject: [PATCH 056/258] Skip pacman builds for now part 2 --- .travis.yml | 8 ++++---- scripts/build-linux.sh | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index ef907fd9b..4fd2b9f04 100644 --- a/.travis.yml +++ b/.travis.yml @@ -194,10 +194,10 @@ jobs: - if [ ! -z "$TRAVIS_TAG" ]; then cp -rf dist/lando.deb release/lando-$TRAVIS_TAG.deb; fi - if [ ! -z "$TRAVIS_TAG" ]; then cp -rf dist/lando.deb release/lando-stable.deb; fi # pacman - - cp -rf dist/lando.pacman release/lando-latest-dev.pacman - - cp -rf dist/lando.pacman release/lando-$TRAVIS_COMMIT-dev.pacman - - if [ ! -z "$TRAVIS_TAG" ]; then cp -rf dist/lando.pacman release/lando-$TRAVIS_TAG.pacman; fi - - if [ ! -z "$TRAVIS_TAG" ]; then cp -rf dist/lando.pacman release/lando-stable.pacman; fi + # - cp -rf dist/lando.pacman release/lando-latest-dev.pacman + # - cp -rf dist/lando.pacman release/lando-$TRAVIS_COMMIT-dev.pacman + # - if [ ! -z "$TRAVIS_TAG" ]; then cp -rf dist/lando.pacman release/lando-$TRAVIS_TAG.pacman; fi + # - if [ ! -z "$TRAVIS_TAG" ]; then cp -rf dist/lando.pacman release/lando-stable.pacman; fi # rpm - cp -rf dist/lando.rpm release/lando-latest-dev.rpm - cp -rf dist/lando.rpm release/lando-$TRAVIS_COMMIT-dev.rpm diff --git a/scripts/build-linux.sh b/scripts/build-linux.sh index c07a97f8b..1ad73b890 100755 --- a/scripts/build-linux.sh +++ b/scripts/build-linux.sh @@ -48,5 +48,5 @@ cd .. && mkdir -p dist # Build our three packages cd ../.. ./scripts/build-pkg.sh deb $LANDO_VERSION -# ./scripts/build-pkg.sh pacman $LANDO_VERSION +./scripts/build-pkg.sh pacman $LANDO_VERSION ./scripts/build-pkg.sh rpm $LANDO_VERSION From 50cce0eeeaeb419cdbef55fbe90109889cecaad4 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 10:34:51 -0500 Subject: [PATCH 057/258] Rollback v3.0.25 to prep for rerelease --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 8a8c5ebb2..9c1efd393 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "lando", "description": "The best local development solution in the galaxy.", "license": "GPL-3.0", - "version": "3.0.25", + "version": "3.0.24", "repository": { "type": "git", "url": "https://github.com/lando/lando" @@ -178,4 +178,4 @@ "vuepress-plugin-robots": "^1.0.1", "vuepress-plugin-sitemap": "https://github.com/ekoeryanto/vuepress-plugin-sitemap#dd8b9763b2c7939668a67f2afa34de501dea45d4" } -} \ No newline at end of file +} From 0f52d36532336d76e9d736bcd29102aac62fa258 Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 10:37:29 -0500 Subject: [PATCH 058/258] Remove pacman part3 --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 4fd2b9f04..ce9e023f1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -221,7 +221,7 @@ jobs: secure: UXDea6KLTOOiUaUfhYqE7stUY74VE2gOdi3No5NscD0Lg3xB/EMf1wzpVe2nuTpjn1CbDBsGXXHqRRpy2IZj6qp21D39+Wygznv9PpSGPgTAB2ZHRYhpux1Qf/HxD8R/NhvISNMXukNLyd66OyiJlz5RWoLWQvLIiJgT1Uczc3Sj8iOJOmYaxQZku/3/q/LmjKKHVJ9vq7ail4l4SoNmLqh6sdDt9utJtavWHMa0hN5kF+CwoV5Vk/z2RFzYNInGwlJggwV7Y/Kf3TmOQv0CiKgxdEQqR8LfTDGIvkxFwpPSf7JnQYnsZWcOWW08oousN7tjc1L1ow2dzPnT2zRYNyx73FwkjWtZ7SLQCkU95pq6FgSy31+w6iWU6Rvwd9mgdX4sfxgdwxLwiF38Rki5TxXtMRGWW1qYRYvnCcc7gpPUPFv0PzsQYZiFSGxMF3uKdKxmKzYd+tfCMvE5YhfkDtCM+LeJBlSL5hZspMUezXEFtiKSv7fDmBKtGGFUsEruNqMphKEbH1kY1UT9SXUu+uxWN40ciJTXfQXJAGMSh34WkZFAgEP/r61+SZDlpuyYPQ8l8fOOcX2uaJYD0LJBSERVmVAX00SNxWSVdTTGibadRXWWuJ4gd4PGCXUhSJI9r1QLfMLyZtt5P3i9SUL2X4cO9isKysBjOq/5DZXjqq0= file: - release/lando-$TRAVIS_TAG.deb - - release/lando-$TRAVIS_TAG.pacman + # - release/lando-$TRAVIS_TAG.pacman - release/lando-$TRAVIS_TAG.rpm skip_cleanup: true on: From c2242af67200ce475d04e1692336d7875f9711da Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 2 Feb 2021 10:38:19 -0500 Subject: [PATCH 059/258] release v3.0.25 --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 9c1efd393..8a8c5ebb2 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "lando", "description": "The best local development solution in the galaxy.", "license": "GPL-3.0", - "version": "3.0.24", + "version": "3.0.25", "repository": { "type": "git", "url": "https://github.com/lando/lando" @@ -178,4 +178,4 @@ "vuepress-plugin-robots": "^1.0.1", "vuepress-plugin-sitemap": "https://github.com/ekoeryanto/vuepress-plugin-sitemap#dd8b9763b2c7939668a67f2afa34de501dea45d4" } -} +} \ No newline at end of file From b82ab410781e2a1b08064d6f3b3bbec1354312f8 Mon Sep 17 00:00:00 2001 From: edvwib Date: Wed, 3 Feb 2021 15:57:11 +0100 Subject: [PATCH 060/258] move changelog to 2021 --- docs/.vuepress/config.js | 1 + docs/help/2020-changelog.md | 18 ------------------ docs/help/2021-changelog.md | 19 +++++++++++++++++++ 3 files changed, 20 insertions(+), 18 deletions(-) create mode 100644 docs/help/2021-changelog.md diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index 2ac58356d..2c58b0674 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -235,6 +235,7 @@ module.exports = { title: 'Changelog', collapsable: false, children: [ + '2021-changelog', '2020-changelog', '2019-changelog', '2018-changelog', diff --git a/docs/help/2020-changelog.md b/docs/help/2020-changelog.md index bae4227ae..bde4f09bd 100644 --- a/docs/help/2020-changelog.md +++ b/docs/help/2020-changelog.md @@ -1,23 +1,5 @@ # 2020 -## v3.0.25 - [February 2, 2020](https://github.com/lando/lando/releases/tag/v3.0.25) - -Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). - -* Added support for `lagoon.type == none` [#2828](https://github.com/lando/lando/issues/2828) -* Added `6.0` to list of supported `redis` versions -* Added "dumb" support for the `drupal9` `pantheon` framework [#2831](https://github.com/lando/lando/issues/2831) -* Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) -* Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) -* Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) -* Fixed bug causing `port` to not be passed in correctly when authing against custom `lagoon` instance -* Improved `lando pull` for `lagoon` recipes to handle other files directory locations [#2762](https://github.com/lando/lando/issues/2762) -* Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) -* Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) -* Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` in _most_ `php` images -* Updated `pantheon` recipe to use `terminus` version `2.5.0` -* Updated to Docker Desktop `3.1.0` and provided wider future patch support because https://github.com/docker/roadmap/issues/183 - ## v3.0.24 - [December 14, 2020](https://github.com/lando/lando/releases/tag/v3.0.24) Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). diff --git a/docs/help/2021-changelog.md b/docs/help/2021-changelog.md new file mode 100644 index 000000000..e3f2f21f2 --- /dev/null +++ b/docs/help/2021-changelog.md @@ -0,0 +1,19 @@ +# 2021 + +## v3.0.25 - [February 2, 2021](https://github.com/lando/lando/releases/tag/v3.0.25) + +Lando is **free** and **open source** software that relies on contributions from developers like you! If you like Lando then help us spend more time making, updating and supporting it by [contributing](https://github.com/sponsors/lando). + +* Added support for `lagoon.type == none` [#2828](https://github.com/lando/lando/issues/2828) +* Added `6.0` to list of supported `redis` versions +* Added "dumb" support for the `drupal9` `pantheon` framework [#2831](https://github.com/lando/lando/issues/2831) +* Fixed bug causing build hook installed `composer` version to not load correctly in `platformsh` recipe [#2826](https://github.com/lando/lando/issues/2826) +* Fixed bug causing `nvm` installed `node` versions to not load correctly in `platformsh` recipe when invoked via tooling [#2820](https://github.com/lando/lando/issues/2820) +* Fixed bug causing `composer` install to fail on `php` `8.0` [#2729](https://github.com/lando/lando/issues/2729) +* Fixed bug causing `port` to not be passed in correctly when authing against custom `lagoon` instance +* Improved `lando pull` for `lagoon` recipes to handle other files directory locations [#2762](https://github.com/lando/lando/issues/2762) +* Improved error message when `lando` cannot detect any `platformsh` applications for `platformsh` recipes [#2822](https://github.com/lando/lando/issues/2822) +* Improved error message when `lando` cannot detect a `lagoon.yml` for `lagoon` recipes [#2818](https://github.com/lando/lando/issues/2818) +* Updated `pantheon` recipe to use `wkhtmltopdf` version `0.12.5` in _most_ `php` images +* Updated `pantheon` recipe to use `terminus` version `2.5.0` +* Updated to Docker Desktop `3.1.0` and provided wider future patch support because https://github.com/docker/roadmap/issues/183 From a294531d463bf8d2614e7799e1fe0c63e5e4052b Mon Sep 17 00:00:00 2001 From: Alec Reynolds Date: Wed, 3 Feb 2021 12:16:57 -0800 Subject: [PATCH 061/258] Readability edits to the WSL2 guide. --- .../setup-lando-on-windows-with-wsl-2.md | 34 +++++++++++-------- 1 file changed, 20 insertions(+), 14 deletions(-) diff --git a/docs/guides/setup-lando-on-windows-with-wsl-2.md b/docs/guides/setup-lando-on-windows-with-wsl-2.md index 7d56a7e56..9a5fb71bc 100644 --- a/docs/guides/setup-lando-on-windows-with-wsl-2.md +++ b/docs/guides/setup-lando-on-windows-with-wsl-2.md @@ -29,41 +29,47 @@ feed: -Windows Development used to be something that caused most web developers agony and pain, but with the introduction of WSL, this is no longer quite so. With the introduction of WSL2, Microsoft has given us a near-native Linux experience for developing web applications using WSL2. +Developing on Windows used to cause web developers agony and pain, but with the introduction of WSL, this is no longer quite so. WSL2 provides a near-native Linux experience for developing web applications on Windows computers. -Long time Mac or Windows Lando users will be familiar with the long standing performance difficulties associated with file system access when using Docker in a non-linux host environment. WSL2 manages to bypass the majority of this performance penalty by never mounting your source code on a non-linux filesystem. Here is the best (highest performance) way to setup Docker (and Lando) on a Windows 10 machine in 2021: +Longtime Mac or Windows Lando users will be familiar with the performance difficulties associated with file system access when using Docker in a non-linux host environment. Traditionally, running Docker on Mac or Windows requires a virtual machine environment. Sharing files across the boundary between your native OS and the Linux OS running within this virtual environment creates significant performance issues. -## Pre-Req +WSL2 manages to bypass the majority of this performance penalty by never mounting your source code on a non-Linux filesystem. Here is the best (highest performance) way to setup Docker (and Lando) on a Windows 10 machine in 2021: -You will want to make sure that if you have an existing Docker or WSL setup, that you are **not** using the Docker + WSL2 backend. If you have this setup, things are going to get funky and break. It is very sad, very frustrating, so if you are here, do yourself a favor and uninstall the Docker Desktop WSL2 backend. +## Prerequisites -You also need to ensure your machine supports virtualization (Vt-d, etc.). You don't need to have Windows 10 pro like the traditional Lando on Windows setup, as WSL doesn't require it. +**1. Uninstall Pre-existing Docker + WSL2 Backend** +You will want to make sure that, if you have an existing Docker or WSL setup, you are **not** using the Docker + WSL2 backend. If you have this setup, [you're going to have a bad time](https://www.youtube.com/watch?v=ynxPshq8ERo). It is very sad, very frustrating, so if you are here, do yourself a favor and uninstall the Docker Desktop WSL2 backend. -## Get WSL2 rolling +**2. Make Sure Your Machine Supports Virtualization** +You also need to ensure your machine supports virtualization (Vt-d, etc.). If you're not sure, you can [check this in Task Manager](https://www.shaileshjha.com/how-to-find-out-if-intel-vt-x-or-amd-v-virtualization-technology-is-supported-in-windows-10-windows-8-windows-vista-or-windows-7-machine). You don't need to have Windows 10 Pro like the traditional Lando on Windows setup, as WSL doesn't require it. -The first thing we need to do is enable WSL2. to do so, open the start menu and search for "Turn Windows features on or off". In the resulting window, we want to check 'Windows Subsystem for Linux' and 'Virtual Machine Platform' and then click 'ok'. This starts the system installed for WSL and will ask us to restart after it downloads the stuff it needs. This really only gives you the WSL1 setup, and you need to download a kernel update to get WSL2 going, see the (Microsoft docs on installing the kernel update)[https://docs.microsoft.com/en-us/windows/wsl/install-win10#step-4---download-the-linux-kernel-update-package]. +## Get WSL2 rolling -After you install the kernel update, make sure to launch a powershell and run `wsl --set-default-version 2` to default to WSL 2. +The first thing we need to do is enable WSL2. To do so... -After installing the kernel update, its time to head to the Microsoft store and install a Linux distro. I am going to choose Ubuntu 18.04 LTS, since it is the most common distro for Lando users and our handy (Hyperdrive)[https://github.com/lando/hyperdrive] supports it. +1. Open the start menu and search for "Turn Windows features on or off". +2. In the resulting window, check 'Windows Subsystem for Linux' and 'Virtual Machine Platform' and then click 'ok'. This starts the system installed for WSL and will ask us to restart after it downloads the stuff it needs. This really only gives you the WSL1 setup. To get WSL2... +3. Download a kernel update to get WSL2 going. see the (Microsoft docs on installing the kernel update)[https://docs.microsoft.com/en-us/windows/wsl/install-win10#step-4---download-the-linux-kernel-update-package]. +4. After you install the kernel update, launch a powershell and run `wsl --set-default-version 2` to default to WSL 2. +5. Head to the Microsoft store and install a Linux distro. I am going to choose [Ubuntu 18.04 LTS](https://www.microsoft.com/en-us/p/ubuntu-1804-lts/9n9tngvndl3q), since it is the most common distro for Lando users and our handy (Hyperdrive)[https://github.com/lando/hyperdrive] supports it. ## Jump into Hyperspace -After installing the latest LTS Ubuntu, using Hyperdrive makes the rest extremely easy. We simply lauch a bash shell in the WSL instance, follow the user setup process, and then follow the hyperdrive instructions. +After installing the latest LTS Ubuntu, using Hyperdrive makes the rest extremely easy. We simply launch a bash shell in the WSL instance, follow the user setup process, and then follow the Hyperdrive instructions in your terminal. ## Rules to keep your setup easy and happy -1. **never** run a lando app from within the default directory that WSL drops you into (`/mnt/c/Users/whateveruser`). This is the Windows filesystem mounted into your WSL instance, and it suffers from the filesystem performance issues that this setup avoids, therefore making going through the trouble of setting this up pointless. -2. You have to start Docker every time you start up the WSL2 instance. I just run `sudo service docker start` but you can probably do some `.bashrc` magic to do this automatically. This is because the WSL2 distros have no init system, so docker doesn't auto start. +1. **Never** run a Lando app from within the default directory that WSL drops you into (`/mnt/c/Users/whateveruser`). This is the Windows filesystem mounted into your WSL instance, and it suffers from the filesystem performance issues that this setup avoids, therefore making going through the trouble of setting this up pointless. +2. You have to start Docker every time you start up the WSL2 instance. I just run `sudo service docker start` but you can probably do some `.bashrc` magic to do this automatically. This is because the WSL2 distros have no init system, so Docker doesn't auto start. 3. VS Code is the absolute easiest editor to use with this setup. Microsoft has some extensions that make working with your WSL filesystem very easy. Vim/Neovim also work great, but using an editor like PHPStorm currently requires some extra setup if you want decent performance. ## Day to day development -You'll want to do all of your shell activity from within the WSL system, and you treat it generally just like a linux development box. You can run `code .` from the directory of any project you're working on and it will lauch VS Code, properly setup to develop within WSL. If you launch the terminal within WSL, it is going to work just like you expect and open the session within the WSL system. +You'll want to do all of your shell activity from within the WSL system, and you treat it like a separate Linux development box. You can run `code .` from the directory of any project you're working on and it will lauch VS Code, properly setup to develop within WSL. If you launch the terminal within WSL, it is going to work just like you expect and open the session within the WSL system. ## Some caveats -Performance is generally very good with this approach, however, stability can at times leave something to be be desired. Occassional freezes under heavy load are fairly common place, and seem to be resolved by rebooting the system. All things considered, the reduction in CPU load, battery drain, and the accompanied increase in the speed of every single action you take (accessing site pages, running any CLI commands) more than outweighs the disruption of these occasional issues for most users. Hopefully stability will continue to increase with time +Performance is generally very good with this approach, however, stability can at times leave something to be be desired. Occassional freezes under heavy load are fairly commonplace, and seem to be resolved by rebooting the system. All things considered, the reduction in CPU load, battery drain, and the accompanied increase in the speed of every single action you take (accessing site pages, running any CLI commands) more than outweighs the disruption of these occasional issues for most users. Hopefully stability will continue to increase with time. From 89607878d41028306046920521b8096aa4749e19 Mon Sep 17 00:00:00 2001 From: Jon Pugh Date: Thu, 4 Feb 2021 08:44:53 -0500 Subject: [PATCH 062/258] Fix the filename in the error message. --- integrations/lando-lagoon/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/integrations/lando-lagoon/app.js b/integrations/lando-lagoon/app.js index 4f2c07585..d433b98f0 100644 --- a/integrations/lando-lagoon/app.js +++ b/integrations/lando-lagoon/app.js @@ -68,7 +68,7 @@ module.exports = (app, lando) => { app.events.on('pre-init', 1, () => { // Error if we don't have at least one docker service or any lagoon config if (_.isEmpty(app.lagoon.containers) || _.isEmpty(app.lagoon.config.lagoon)) { - throw Error(`The lagoon recipe requires a lagoon.yml in ${app.root} but we couldn't find one! ` + + throw Error(`The lagoon recipe requires a .lagoon.yml in ${app.root} but we couldn't find one! ` + `Check out https://docs.lando.dev/config/lagoon.html to see how all the magic works!`); } From 8b9b795542cc61a74b383c2c87ef32879d156132 Mon Sep 17 00:00:00 2001 From: "Geoff St. Pierre" Date: Thu, 4 Feb 2021 12:55:15 -0500 Subject: [PATCH 063/258] Take recipe bullet list out of internal page nav. --- docs/config/recipes.md | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/docs/config/recipes.md b/docs/config/recipes.md index 7faf99647..8362ad3b0 100644 --- a/docs/config/recipes.md +++ b/docs/config/recipes.md @@ -45,21 +45,21 @@ config: The following recipes are currently offered. Please check out each one to learn how to specifically use them. -* ### [Backdrop](./backdrop.md) -* ### [Drupal 6](./drupal6.md) -* ### [Drupal 7](./drupal7.md) -* ### [Drupal 8](./drupal8.md) -* ### [Drupal 9](./drupal9.md) -* ### [Joomla](./joomla.md) -* ### [Lagoon](./lagoon.md) **(BETA)** -* ### [Laravel](./laravel.md) -* ### [LAMP](./lamp.md) -* ### [LEMP](./lemp.md) -* ### [MEAN](./mean.md) -* ### [Pantheon](./pantheon.md) -* ### [Platform.sh](./platformsh.md) **(BETA)** -* ### [Symfony](./symfony.md) -* ### [WordPress](./wordpress.md) +* [Backdrop](./backdrop.md) +* [Drupal 6](./drupal6.md) +* [Drupal 7](./drupal7.md) +* [Drupal 8](./drupal8.md) +* [Drupal 9](./drupal9.md) +* [Joomla](./joomla.md) +* [Lagoon](./lagoon.md) **(BETA)** +* [Laravel](./laravel.md) +* [LAMP](./lamp.md) +* [LEMP](./lemp.md) +* [MEAN](./mean.md) +* [Pantheon](./pantheon.md) +* [Platform.sh](./platformsh.md) **(BETA)** +* [Symfony](./symfony.md) +* [WordPress](./wordpress.md) ## Extending and Overriding Recipes From f0c35c4a07970811aa2b29060382be9866a9bd60 Mon Sep 17 00:00:00 2001 From: Mike Milano Date: Thu, 4 Feb 2021 09:57:11 -0800 Subject: [PATCH 064/258] Environment selection & initial code pull --- experimental/lando-acquia/lib/api.js | 11 ++++ experimental/lando-acquia/lib/auth.js | 54 +++++++++++++++++++ .../lando-acquia/recipes/acquia/init.js | 46 ++++++++++++++-- 3 files changed, 108 insertions(+), 3 deletions(-) create mode 100644 experimental/lando-acquia/lib/auth.js diff --git a/experimental/lando-acquia/lib/api.js b/experimental/lando-acquia/lib/api.js index 747f60819..847cab792 100644 --- a/experimental/lando-acquia/lib/api.js +++ b/experimental/lando-acquia/lib/api.js @@ -71,6 +71,17 @@ module.exports = class AcquiaApi { }); } + getEnvironments(appId) { + return axios.get(`https://cloud.acquia.com/api/applications/${appId}/environments`).then(res => { + const total = res.data.total; + this.environments = total === 0 ? [] : res.data._embedded.items; + return this.environments; + }) + .catch(error => { + console.log(error); + }); + } + /** * Sets this.account; Called in this.auth(). * @return {Promise} diff --git a/experimental/lando-acquia/lib/auth.js b/experimental/lando-acquia/lib/auth.js new file mode 100644 index 000000000..a43eb4385 --- /dev/null +++ b/experimental/lando-acquia/lib/auth.js @@ -0,0 +1,54 @@ +'use strict'; + +// Modules +const _ = require('lodash'); + +// Stuff +const getTokens = tokens => _(tokens).map(token => ({name: token.email, value: token.token})).value(); + +// Helper to get pantheon auth non-interactive options +const getInteractiveOptions = (tokens = []) => ({ + 'auth': { + interactive: { + choices: _.flatten([getTokens(tokens), [{name: 'add or refresh a token', value: 'more'}]]), + when: answers => !_.isEmpty(tokens), + weight: 100, + }, + }, + 'api-key': { + hidden: true, + interactive: { + name: 'auth', + type: 'text', + message: 'Enter your Acquia API key', + when: answers => _.isEmpty(tokens) || (_.get(answers, 'auth', '') === 'more'), + weight: 101, + }, + }, + 'api-secret': { + hidden: true, + interactive: { + name: 'auth', + type: 'password', + message: 'Enter your Acquia API secret', + when: answers => _.isEmpty(tokens) || (_.get(answers, 'auth', '') === 'more'), + weight: 101, + }, + }, +}); + +// Helper to get acquia auth non-interactive options +const getNonInteractiveOptions = (token, email) => ({ + 'auth': { + default: token, + defaultDescription: email, + }, +}); + +/* + * Helper to build a pull command + */ +exports.getAuthOptions = ({email = false, token = false} = {}, tokens = []) => { + if (email && token) return getNonInteractiveOptions(token, email); + else return getInteractiveOptions(tokens); +}; diff --git a/experimental/lando-acquia/recipes/acquia/init.js b/experimental/lando-acquia/recipes/acquia/init.js index e7e8128af..c2f8f5618 100644 --- a/experimental/lando-acquia/recipes/acquia/init.js +++ b/experimental/lando-acquia/recipes/acquia/init.js @@ -8,6 +8,7 @@ const utils = require('../../lib/utils'); const api = new API(); const acquiaTokenCache = 'acquia.tokens'; const acquiaApps = []; +let acquiaEnvs = []; // Helper to get tokens const getTokens = (lando, tokens = []) => { @@ -34,12 +35,24 @@ const getAutoCompleteSites = (answers, lando, input = null) => { } return api.getApplications().then(apps => { if (apps && Array.isArray(apps)) { - apps.map(item => acquiaApps.push({name: item.name, value: item.name})); + apps.map(item => acquiaApps.push({name: item.name, value: item.uuid})); return lando.Promise.resolve(acquiaApps); } }); }; +const getAutoCompleteEnvs = (answers, lando, input = null) => { + if (!_.isEmpty(acquiaEnvs)) { + return lando.Promise.resolve(acquiaEnvs).filter(app => _.startsWith(app.name, input)); + } + return api.getEnvironments(answers['acquia-app']).then(envs => { + if (envs && Array.isArray(envs)) { + acquiaEnvs = envs.map(item => (_.merge({name: item.name, value: item.id}, item))); + return acquiaEnvs; + } + }); +}; + module.exports = { name: 'acquia', options: lando => ({ @@ -112,11 +125,11 @@ module.exports = { }, }, 'acquia-app': { - describe: 'An Acquia site ID', + describe: 'An Acquia app uuid', string: true, interactive: { type: 'autocomplete', - message: 'Which site?', + message: 'Which application?', source: (answers, input) => { return getAutoCompleteSites(answers, lando, input); }, @@ -124,6 +137,19 @@ module.exports = { weight: 540, }, }, + 'acquia-env': { + describe: 'An Acquia environment', + string: true, + interactive: { + type: 'autocomplete', + message: 'Which environment?', + source: (answers, input) => { + return getAutoCompleteEnvs(answers, lando, input); + }, + when: answers => answers.recipe === 'acquia', + weight: 540, + }, + }, }), overrides: { name: { @@ -139,6 +165,20 @@ module.exports = { sources: [{ name: 'acquia', label: 'acquia', + build: (options, lando) => ([ + {name: 'get-git-url', func: (options, lando) => { + // Set git url & branch from env + const env = _.find(acquiaEnvs, item => item.id === options['acquia-env']); + options['acquia-git-url'] = env.vcs.url; + options['acquia-git-branch'] = env.vcs.path; + }}, + { + name: 'clone-repo', + cmd: options => + `/helpers/get-remote-url.sh ${options['acquia-git-url']} "--branch ${options['acquia-git-branch']}"`, + remove: 'true', + }, + ]), }], build: (options, lando) => { return { From 5e06a280ec3129af7005ea9221d32c85cd0cded4 Mon Sep 17 00:00:00 2001 From: "Geoff St. Pierre" Date: Thu, 4 Feb 2021 13:46:59 -0500 Subject: [PATCH 065/258] Fixing sponsors links. --- docs/.vuepress/theme/components/LayoutSponsors.vue | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/.vuepress/theme/components/LayoutSponsors.vue b/docs/.vuepress/theme/components/LayoutSponsors.vue index 156049971..b4fdd444b 100644 --- a/docs/.vuepress/theme/components/LayoutSponsors.vue +++ b/docs/.vuepress/theme/components/LayoutSponsors.vue @@ -14,6 +14,9 @@