diff --git a/.github/workflows/build-pantheon-images.yml b/.github/workflows/build-pantheon-images.yml index 523ccd7..aab1fec 100644 --- a/.github/workflows/build-pantheon-images.yml +++ b/.github/workflows/build-pantheon-images.yml @@ -9,7 +9,7 @@ on: jobs: buildx: - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 env: TERM: xterm strategy: @@ -55,7 +55,7 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up QEMU uses: docker/setup-qemu-action@v2 - name: Set up Docker Buildx diff --git a/.github/workflows/pr-docs-tests.yml b/.github/workflows/pr-docs-tests.yml index 4aaef50..bf9c8de 100644 --- a/.github/workflows/pr-docs-tests.yml +++ b/.github/workflows/pr-docs-tests.yml @@ -9,15 +9,15 @@ jobs: strategy: matrix: os: - - ubuntu-22.04 + - ubuntu-24.04 node-version: - '18' steps: # Install deps and cache - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: npm diff --git a/.github/workflows/pr-drupal10-tests.yml b/.github/workflows/pr-drupal10-tests.yml deleted file mode 100644 index e754729..0000000 --- a/.github/workflows/pr-drupal10-tests.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: Drupal 10 Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/drupal10 - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/pr-drupal7-tests.yml b/.github/workflows/pr-drupal7-tests.yml deleted file mode 100644 index 9b62ecc..0000000 --- a/.github/workflows/pr-drupal7-tests.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: Drupal 7 Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/drupal7 - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/pr-drupal8-tests.yml b/.github/workflows/pr-drupal8-tests.yml deleted file mode 100644 index 8d2dfee..0000000 --- a/.github/workflows/pr-drupal8-tests.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: Drupal 8 Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/drupal8 - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/pr-drupal9-tests.yml b/.github/workflows/pr-drupal9-tests.yml deleted file mode 100644 index 57d628e..0000000 --- a/.github/workflows/pr-drupal9-tests.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: Drupal 9 Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/drupal9 - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/pr-linter.yml b/.github/workflows/pr-linter.yml index 29a6d74..dcad303 100644 --- a/.github/workflows/pr-linter.yml +++ b/.github/workflows/pr-linter.yml @@ -9,15 +9,15 @@ jobs: strategy: matrix: os: - - ubuntu-22.04 + - ubuntu-24.04 node-version: - '18' steps: # Install deps and cache - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: npm diff --git a/.github/workflows/pr-pantheon-tests.yml b/.github/workflows/pr-pantheon-tests.yml index 13c4b0d..1cf9392 100644 --- a/.github/workflows/pr-pantheon-tests.yml +++ b/.github/workflows/pr-pantheon-tests.yml @@ -1,4 +1,4 @@ -name: Lando Init Tests +name: Pantheon Tests on: pull_request: @@ -10,24 +10,32 @@ jobs: TERM: xterm PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} strategy: + fail-fast: false matrix: leia-test: + - examples/drupal7 + - examples/drupal8 + - examples/drupal9 + - examples/drupal10 - examples/init - examples/pantheon-downstreamer-1 - examples/pantheon-downstreamer-2 + - examples/wordpress + - examples/wordpressnetworkdomain + # - examples/wordpressnetworkfolder lando-version: - - 3-dev-slim + - 3-edge-slim os: - - ubuntu-22.04 + - ubuntu-24.04 node-version: - '18' steps: # Install deps and cache - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: npm @@ -40,7 +48,7 @@ jobs: version: dev sync: false - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 + uses: lando/setup-lando@v3 with: lando-version: ${{ matrix.lando-version }} config: | diff --git a/.github/workflows/pr-unit-tests.yml b/.github/workflows/pr-unit-tests.yml index f43a08f..cfb250a 100644 --- a/.github/workflows/pr-unit-tests.yml +++ b/.github/workflows/pr-unit-tests.yml @@ -10,16 +10,16 @@ jobs: matrix: os: - windows-2022 - - ubuntu-22.04 + - ubuntu-24.04 - macos-12 node-version: - '18' steps: # Install deps and cache - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} cache: npm diff --git a/.github/workflows/pr-wordpress-tests.yml b/.github/workflows/pr-wordpress-tests.yml deleted file mode 100644 index 130f3b8..0000000 --- a/.github/workflows/pr-wordpress-tests.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: WordPress Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/wordpress - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/pr-wordpressnetworkdomain-tests.yml b/.github/workflows/pr-wordpressnetworkdomain-tests.yml deleted file mode 100644 index b5ade71..0000000 --- a/.github/workflows/pr-wordpressnetworkdomain-tests.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: WordPress Network Domain Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/wordpressnetworkdomain - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/pr-wordpressnetworkfolder.yml b/.github/workflows/pr-wordpressnetworkfolder.yml deleted file mode 100644 index ec16bc6..0000000 --- a/.github/workflows/pr-wordpressnetworkfolder.yml +++ /dev/null @@ -1,63 +0,0 @@ -name: WordPress Network Folder Tests - -on: - pull_request: - -jobs: - leia-tests: - runs-on: ${{ matrix.os }} - env: - TERM: xterm - PANTHEON_MACHINE_TOKEN: ${{ secrets.PANTHEON_MACHINE_TOKEN }} - strategy: - matrix: - leia-test: - - examples/wordpressnetworkfolder - lando-version: - - 3-dev-slim - os: - - ubuntu-22.04 - node-version: - - '18' - - steps: - # Install deps and cache - - name: Checkout code - uses: actions/checkout@v3 - - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - cache: npm - - name: Install NPM dependencies - run: npm clean-install --production --prefer-offline --frozen-lockfile - - name: Bundle Deps - uses: lando/prepare-release-action@v3 - with: - lando-plugin: true - version: dev - sync: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Setup lando ${{ matrix.lando-version }} - uses: lando/setup-lando@v2 - with: - lando-version: ${{ matrix.lando-version }} - config: | - setup.skipCommonPlugins=true - setup.plugins.@lando/pantheon=/home/runner/work/pantheon/pantheon - telemetry: false - - name: Run Leia Tests - uses: lando/run-leia-action@v2 - with: - leia-test: "./${{ matrix.leia-test }}/README.md" - cleanup-header: "Destroy tests" - retry: 3 - shell: bash - stdin: true diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d3b50e7..88afa09 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -15,15 +15,15 @@ jobs: strategy: matrix: os: - - ubuntu-22.04 + - ubuntu-24.04 node-version: - '18' steps: # Install deps and cache - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install node ${{ matrix.node-version }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} registry-url: https://registry.npmjs.org diff --git a/.lando.yml b/.lando.yml index f408725..8eca86e 100644 --- a/.lando.yml +++ b/.lando.yml @@ -1,23 +1,24 @@ -name: lando-pantheon-plugin +name: docs.pantheon +proxy: + cli: + - docs.pantheon.lndo.site:5173 services: cli: - api: 3 - type: lando - services: - image: node:18 - command: sleep infinity - working_dir: /app - ports: - - 8080:8080 - build: - - npm install + api: 4 + image: node:18 + command: sleep infinity + ports: + - 5173:5173/http scanner: false - ssl: false - sslExpose: false + user: node + build: + app: | + npm install tooling: node: service: cli - vuepress: - service: cli npm: service: cli + vitepress: + service: cli + cmd: npx vitepress diff --git a/builders/pantheon-php.js b/builders/pantheon-php.js index ee96343..e736e56 100644 --- a/builders/pantheon-php.js +++ b/builders/pantheon-php.js @@ -9,13 +9,13 @@ const utils = require('./../lib/utils.js'); const loadScripts = options => { const lando = _.get(options, '_app._lando'); const landoPhpScriptsPath = path.join(path.dirname(require.resolve('@lando/php/package.json')), 'scripts'); + // Move the script to the confDir and make executable. if (fs.existsSync(landoPhpScriptsPath)) { const confDir = path.join(lando.config.userConfRoot, 'scripts'); const dest = lando.utils.moveConfig(landoPhpScriptsPath, confDir); lando.utils.makeExecutable(fs.readdirSync(dest), dest); - lando.log.debug('automoved scripts from %s to %s and set to mode 755', - landoPhpScriptsPath, confDir); + lando.log.debug('automoved scripts from %s to %s and set to mode 755', landoPhpScriptsPath, confDir); } }; @@ -49,6 +49,7 @@ module.exports = { options.confSrc = path.resolve(__dirname, '..', 'config'); options.nginxServiceType = 'pantheon-nginx'; loadScripts(options); + super(id, options, factory); }; }, diff --git a/builders/pantheon-solr.js b/builders/pantheon-solr.js index 7629f41..8479ef9 100644 --- a/builders/pantheon-solr.js +++ b/builders/pantheon-solr.js @@ -6,9 +6,13 @@ const LandoSolr = require('@lando/solr/builders/solr.js'); module.exports = { name: 'pantheon-solr', parent: '_service', + config: { + ssl: true, + sslExpose: false, + }, builder: (parent, config) => class PantheonSolr extends LandoSolr.builder(parent, LandoSolr.config) { constructor(id, options = {}) { - super(id, options); + super(id, {...config, ...options}); }; }, }; diff --git a/dockerfiles/3.6-solr/Dockerfile b/dockerfiles/3.6-solr/Dockerfile index dfef54a..c166df7 100644 --- a/dockerfiles/3.6-solr/Dockerfile +++ b/dockerfiles/3.6-solr/Dockerfile @@ -3,7 +3,7 @@ FROM debian:stretch-slim # Versions -ENV SOLR_VERSION 3.6.2 +ENV SOLR_VERSION=3.6.2 # Build out solr on tomcat8 RUN \ diff --git a/dockerfiles/5.3-fpm/Dockerfile b/dockerfiles/5.3-fpm/Dockerfile index 44a4494..436de8a 100644 --- a/dockerfiles/5.3-fpm/Dockerfile +++ b/dockerfiles/5.3-fpm/Dockerfile @@ -3,10 +3,10 @@ FROM devwithlando/php:5.3-fpm-2 # Version information -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 +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 # Install the additional things that make the pantheon RUN apt-get update && apt-get install -y \ diff --git a/dockerfiles/5.5-fpm/Dockerfile b/dockerfiles/5.5-fpm/Dockerfile index 1a7c6f9..d5a659c 100644 --- a/dockerfiles/5.5-fpm/Dockerfile +++ b/dockerfiles/5.5-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:5.5-fpm-2 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.2 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.5.0 -ENV MAVEN_VERSION 3.5.4 +ENV WKHTMLTOPDF_VERSION=0.12.2 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=2.5.0 +ENV MAVEN_VERSION=3.5.4 # Install the additional things that make the pantheon RUN apt-get update && apt-get install -y \ diff --git a/dockerfiles/5.6-fpm/Dockerfile b/dockerfiles/5.6-fpm/Dockerfile index 4fb191d..148d7a6 100644 --- a/dockerfiles/5.6-fpm/Dockerfile +++ b/dockerfiles/5.6-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:5.6-fpm-3 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.5.0 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=2.5.0 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN \ diff --git a/dockerfiles/7.0-fpm/Dockerfile b/dockerfiles/7.0-fpm/Dockerfile index 5a4c05c..e45e15f 100644 --- a/dockerfiles/7.0-fpm/Dockerfile +++ b/dockerfiles/7.0-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:7.0-fpm-3 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.5.0 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=2.5.0 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN \ diff --git a/dockerfiles/7.1-fpm/Dockerfile b/dockerfiles/7.1-fpm/Dockerfile index 21870c4..44385ad 100644 --- a/dockerfiles/7.1-fpm/Dockerfile +++ b/dockerfiles/7.1-fpm/Dockerfile @@ -3,16 +3,19 @@ FROM devwithlando/php:7.1-fpm-3 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.5.0 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=2.5.0 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon -RUN mkdir -p /usr/share/man/man1 \ +RUN \ + echo "deb http://archive.debian.org/debian stretch main non-free contrib" > /etc/apt/sources.list \ + && rm -rf /etc/apt/sources.list.d/pgdg.list \ + && mkdir -p /usr/share/man/man1 \ && apt-get update && apt-get install -y \ - openjdk-11-jdk \ + openjdk-8-jdk \ && rm -f /usr/local/etc/php/conf.d/*-memcached.ini \ && mkdir -p /var/www/.drush \ && mkdir -p /var/www/.backdrush \ diff --git a/dockerfiles/7.2-fpm/Dockerfile b/dockerfiles/7.2-fpm/Dockerfile index 3ef09cd..0b6b82b 100644 --- a/dockerfiles/7.2-fpm/Dockerfile +++ b/dockerfiles/7.2-fpm/Dockerfile @@ -3,16 +3,19 @@ FROM devwithlando/php:7.2-fpm-3 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.5.0 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=2.5.0 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon -RUN mkdir -p /usr/share/man/man1 \ +RUN \ + echo "deb http://archive.debian.org/debian stretch main non-free contrib" > /etc/apt/sources.list \ + && rm -rf /etc/apt/sources.list.d/pgdg.list \ + && mkdir -p /usr/share/man/man1 \ && apt-get update && apt-get install -y \ - openjdk-11-jdk \ + openjdk-8-jdk \ && rm -f /usr/local/etc/php/conf.d/*-memcached.ini \ && mkdir -p /var/www/.drush \ && mkdir -p /var/www/.backdrush \ diff --git a/dockerfiles/7.3-fpm/Dockerfile b/dockerfiles/7.3-fpm/Dockerfile index 7b95e33..56076f7 100644 --- a/dockerfiles/7.3-fpm/Dockerfile +++ b/dockerfiles/7.3-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:7.3-fpm-4 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 2.5.0 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=2.5.0 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN mkdir -p /usr/share/man/man1 \ diff --git a/dockerfiles/7.4-fpm/Dockerfile b/dockerfiles/7.4-fpm/Dockerfile index 803be29..839cda5 100644 --- a/dockerfiles/7.4-fpm/Dockerfile +++ b/dockerfiles/7.4-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:7.4-fpm-4 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 3.0.7 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=3.0.7 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN mkdir -p /usr/share/man/man1 \ diff --git a/dockerfiles/8.0-fpm/Dockerfile b/dockerfiles/8.0-fpm/Dockerfile index 157b537..5087590 100644 --- a/dockerfiles/8.0-fpm/Dockerfile +++ b/dockerfiles/8.0-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:8.0-fpm-4 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 3.3.5 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=3.3.5 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN mkdir -p /usr/share/man/man1 \ diff --git a/dockerfiles/8.1-fpm/Dockerfile b/dockerfiles/8.1-fpm/Dockerfile index c308f92..2349f06 100644 --- a/dockerfiles/8.1-fpm/Dockerfile +++ b/dockerfiles/8.1-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:8.1-fpm-4 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 3.3.5 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=3.3.5 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN mkdir -p /usr/share/man/man1 \ diff --git a/dockerfiles/8.2-fpm/Dockerfile b/dockerfiles/8.2-fpm/Dockerfile index a603020..4fd6871 100644 --- a/dockerfiles/8.2-fpm/Dockerfile +++ b/dockerfiles/8.2-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:8.2-fpm-4 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 3.3.5 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=3.3.5 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN mkdir -p /usr/share/man/man1 \ diff --git a/dockerfiles/8.3-fpm/Dockerfile b/dockerfiles/8.3-fpm/Dockerfile index c454e7a..5303d7c 100644 --- a/dockerfiles/8.3-fpm/Dockerfile +++ b/dockerfiles/8.3-fpm/Dockerfile @@ -3,11 +3,11 @@ FROM devwithlando/php:8.3-fpm-4 # Version information -ENV WKHTMLTOPDF_VERSION 0.12.6 -ENV PHANTOMJS_VERSION 2.1.1 -ENV PHANTOMJS_OLD_VERSION 1.7.0 -ENV LANDO_TERMINUS_VERSION 3.3.5 -ENV TIKA_VERSION 1.18 +ENV WKHTMLTOPDF_VERSION=0.12.6 +ENV PHANTOMJS_VERSION=2.1.1 +ENV PHANTOMJS_OLD_VERSION=1.7.0 +ENV LANDO_TERMINUS_VERSION=3.3.5 +ENV TIKA_VERSION=1.18 # Install the additional things that make the pantheon RUN mkdir -p /usr/share/man/man1 \ diff --git a/dockerfiles/8.8-solr/Dockerfile b/dockerfiles/8.8-solr/Dockerfile index 9f22055..3b3c951 100644 --- a/dockerfiles/8.8-solr/Dockerfile +++ b/dockerfiles/8.8-solr/Dockerfile @@ -1,12 +1,12 @@ # docker build -t devwithlando/pantheon-index:8.8-4 . FROM solr:8.8.2 - + # replace default configset with correct solr8 drupal config ENV SOLR_DOWNLOAD="https://ftp.drupal.org/files/projects/search_api_solr-4.x-dev.tar.gz" ENV SOLR_DEFAULT_CONFIGSET_DIR=/opt/solr/server/solr/configsets/_default/conf RUN wget -qO- $SOLR_DOWNLOAD | tar xvz -C /tmp - + USER root RUN mv /tmp/search_api_solr/jump-start/solr8/config-set/* $SOLR_DEFAULT_CONFIGSET_DIR diff --git a/docs/getting-started.md b/docs/getting-started.md index 514b248..b0c4cc2 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -11,7 +11,7 @@ Before you get started with this recipe, we assume that you have: 1. [Installed Lando](https://docs.lando.dev/getting-started/installation.html) and gotten familiar with [its basics](https://docs.lando.dev/cli/). 2. [Initialized](https://docs.lando.dev/cli/init.html) a [Landofile](https://docs.lando.dev/core/v3) for your codebase for use with this recipe. -3. Read about the various [services](https://docs.lando.dev/core/v3/lando-service.html), [tooling](https://docs.lando.dev/core/v3/tooling.html), [events](https://docs.lando.dev/core/v3/events.html) and [routing](https://docs.lando.dev/core/v3/proxy.html) Lando offers. +3. Read about the various [services](https://docs.lando.dev/core/v3/services/lando.html), [tooling](https://docs.lando.dev/core/v3/tooling.html), [events](https://docs.lando.dev/core/v3/events.html) and [routing](https://docs.lando.dev/core/v3/proxy.html) Lando offers. ## Quick Start diff --git a/docs/index.md b/docs/index.md index 19e824d..59ef931 100644 --- a/docs/index.md +++ b/docs/index.md @@ -15,8 +15,6 @@ Lando provides a snazzy integration that: * Allows you to easily `push` your changes back to Pantheon * Installs `drush`, `terminus` and other power tools. -However, in order to profit, **you must** have an account and a site on Pantheon to be able to use this recipe. If you don't, you can sign up [here](https://pantheon.io/register). +However, in order to profit, **you must** have an account and a site on Pantheon to be able to use this recipe. If you don't, you can sign up [here](https://pantheon.io/). You should also check out Pantheon's [local dev](https://docs.pantheon.io/guides/local-development/) docs. - - diff --git a/examples/.gitkeep b/examples/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/examples/.lando.yml b/examples/.lando.yml new file mode 100644 index 0000000..062eb02 --- /dev/null +++ b/examples/.lando.yml @@ -0,0 +1,3 @@ +name: stealth-plugin-loader +plugins: + "@lando/pantheon": .. diff --git a/examples/drupal10/.lando.upstream.yml b/examples/drupal10/.lando.upstream.yml deleted file mode 100644 index 19ba6c0..0000000 --- a/examples/drupal10/.lando.upstream.yml +++ /dev/null @@ -1,2 +0,0 @@ -plugins: - "@lando/pantheon": ../../.. diff --git a/examples/drupal10/README.md b/examples/drupal10/README.md index b7518fa..49cf5c0 100644 --- a/examples/drupal10/README.md +++ b/examples/drupal10/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test drupal10 site rm -rf drupal10 && mkdir -p drupal10 && cd drupal10 -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-drupal10 +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our drupal10 site successfully cd drupal10 @@ -54,34 +54,34 @@ lando terminus auth:whoami | grep droid@lando.dev # Should have a binding.pem in all the right places cd drupal10 -lando ssh -s appserver -c "stat /var/www/certs/binding.pem" -lando ssh -s appserver -u root -c "stat /root/certs/binding.pem" +lando exec appserver -- "stat /var/www/certs/binding.pem" +lando exec appserver -u root -- "stat /root/certs/binding.pem" # Should set the correct pantheon environment cd drupal10 -lando ssh -c "env" | grep BACKDROP_SETTINGS | grep pantheon -lando ssh -c "env" | grep CACHE_HOST | grep cache -lando ssh -c "env" | grep CACHE_PORT | grep 6379 -lando ssh -c "env" | grep DB_HOST | grep database -lando ssh -c "env" | grep DB_PORT | grep 3306 -lando ssh -c "env" | grep DB_USER | grep pantheon -lando ssh -c "env" | grep DB_PASSWORD | grep pantheon -lando ssh -c "env" | grep DB_NAME | grep pantheon -lando ssh -c "env" | grep FRAMEWORK | grep drupal8 -lando ssh -c "env" | grep FILEMOUNT | grep "sites/default/files" -lando ssh -c "env" | grep PANTHEON_ENVIRONMENT | grep lando -lando ssh -c "env" | grep PANTHEON_INDEX_CORE | grep "\/lando" -lando ssh -c "env" | grep PANTHEON_INDEX_HOST | grep index -lando ssh -c "env" | grep PANTHEON_INDEX_PORT | grep 449 -lando ssh -c "env" | grep PANTHEON_INDEX_SCHEMA | grep "solr\/#\/lando\/schema" -lando ssh -c "env" | grep PANTHEON_INDEX_SCHEME | grep http -lando ssh -c "env" | grep PANTHEON_SITE | grep adab25c2-796f-4051-9f27-04a45f6958f5 -lando ssh -c "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal10 -lando ssh -c "env" | grep php_version | grep "8" -lando ssh -c "env" | grep PRESSFLOW_SETTINGS | grep pantheon -lando ssh -c "env" | grep TERMINUS_ENV | grep dev -lando ssh -c "env" | grep TERMINUS_SITE | grep landobot-drupal10 -lando ssh -c "env" | grep TERMINUS_USER | grep droid@lando.dev +lando exec appserver -- "env" | grep BACKDROP_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep CACHE_HOST | grep cache +lando exec appserver -- "env" | grep CACHE_PORT | grep 6379 +lando exec appserver -- "env" | grep DB_HOST | grep database +lando exec appserver -- "env" | grep DB_PORT | grep 3306 +lando exec appserver -- "env" | grep DB_USER | grep pantheon +lando exec appserver -- "env" | grep DB_PASSWORD | grep pantheon +lando exec appserver -- "env" | grep DB_NAME | grep pantheon +lando exec appserver -- "env" | grep FRAMEWORK | grep drupal8 +lando exec appserver -- "env" | grep FILEMOUNT | grep "sites/default/files" +lando exec appserver -- "env" | grep PANTHEON_ENVIRONMENT | grep lando +lando exec appserver -- "env" | grep PANTHEON_INDEX_CORE | grep "\/lando" +lando exec appserver -- "env" | grep PANTHEON_INDEX_HOST | grep index +lando exec appserver -- "env" | grep PANTHEON_INDEX_PORT | grep 449 +lando exec appserver -- "env" | grep PANTHEON_INDEX_SCHEMA | grep "solr\/#\/lando\/schema" +lando exec appserver -- "env" | grep PANTHEON_INDEX_SCHEME | grep http +lando exec appserver -- "env" | grep PANTHEON_SITE | grep adab25c2-796f-4051-9f27-04a45f6958f5 +lando exec appserver -- "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal10 +lando exec appserver -- "env" | grep php_version | grep "8" +lando exec appserver -- "env" | grep PRESSFLOW_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep TERMINUS_ENV | grep dev +lando exec appserver -- "env" | grep TERMINUS_SITE | grep landobot-drupal10 +lando exec appserver -- "env" | grep TERMINUS_USER | grep droid@lando.dev # Should use php version in pantheon.yml cd drupal10 @@ -89,7 +89,7 @@ lando php -v | grep "PHP 8.3" # Should use the database version in pantheon.yml cd drupal10 -lando ssh -s database -c "mysql -V" | grep 10.4. +lando exec database -- "mysql -V" | grep 10.4. # Should use a varnish http_resp_hdr_len setting of 25k cd drupal10 @@ -102,8 +102,8 @@ docker ps --filter label=com.docker.compose.project=landobotdrupal10 | grep land # Should use the correct default config files cd drupal10 -lando ssh -s appserver -c "cat /usr/local/etc/php/conf.d/zzz-lando-my-custom.ini" | grep "; LANDOPANTHEONPHPINI" -lando ssh -s database -c "cat /opt/bitnami/mariadb/conf/my_custom.cnf" | grep "LANDOPANTHEONMYSQLCNF" +lando exec appserver -- "cat /usr/local/etc/php/conf.d/zzz-lando-my-custom.ini" | grep "; LANDOPANTHEONPHPINI" +lando exec database -- "cat /opt/bitnami/mariadb/conf/my_custom.cnf" | grep "LANDOPANTHEONMYSQLCNF" # Should not have xdebug enabled by defaults cd drupal10 @@ -112,7 +112,7 @@ lando php -m | grep xdebug || echo $? | grep 1 # Should be able to push commits to pantheon cd drupal10 lando pull --code dev --database none --files none -lando ssh -s appserver -c "git rev-parse HEAD > test.log" +lando exec appserver -- "git rev-parse HEAD > test.log" lando push --code dev --database none --files none --message "Testing commit $(git rev-parse HEAD)" # Should allow code pull from protected environments @@ -134,7 +134,7 @@ Run the following commands to trash this app like nothing ever happened. # Should be able to remove our pantheon ssh keys cp -r remove-keys.sh drupal10/remove-keys.sh cd drupal10 -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" cd .. rm -rf drupal10/remove-keys.sh diff --git a/examples/drupal7/README.md b/examples/drupal7/README.md index 688a3f5..460d250 100644 --- a/examples/drupal7/README.md +++ b/examples/drupal7/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test drupal7 site rm -rf drupal7 && mkdir -p drupal7 && cd drupal7 -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-drupal7 +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our drupal7 site successfully cd drupal7 @@ -42,7 +42,7 @@ lando drush status | grep "Connected" # Should have 755 on pulled files cd drupal7 -lando ssh -s appserver -c "stat sites/default/files/field/image/Lando-Calrissian-Cloud-City-Administrator.jpg" | grep "Access" | grep "0755" +lando exec appserver -- "stat sites/default/files/field/image/Lando-Calrissian-Cloud-City-Administrator.jpg" | grep "Access" | grep "0755" # Should have drush cd drupal7 @@ -50,7 +50,7 @@ lando drush version # Should use MariaDB 10.3 cd drupal7 -lando ssh -s database -c "mysql -V" | grep 10.3. +lando exec database -- "mysql -V" | grep 10.3. # Should be able to export DB cd drupal7 @@ -70,41 +70,41 @@ lando terminus auth:whoami | grep droid@lando.dev # Should have a binding.pem in all the right places cd drupal7 -lando ssh -s appserver -c "stat /var/www/certs/binding.pem" -lando ssh -s appserver -u root -c "stat /root/certs/binding.pem" +lando exec appserver -- "stat /var/www/certs/binding.pem" +lando exec --user root appserver -- "stat /root/certs/binding.pem" # Should set the correct pantheon environment cd drupal7 -lando ssh -c "env" | grep BACKDROP_SETTINGS | grep pantheon -lando ssh -c "env" | grep CACHE_HOST | grep cache -lando ssh -c "env" | grep CACHE_PORT | grep 6379 -lando ssh -c "env" | grep DB_HOST | grep database -lando ssh -c "env" | grep DB_PORT | grep 3306 -lando ssh -c "env" | grep DB_USER | grep pantheon -lando ssh -c "env" | grep DB_PASSWORD | grep pantheon -lando ssh -c "env" | grep DB_NAME | grep pantheon -lando ssh -c "env" | grep FRAMEWORK | grep drupal -lando ssh -c "env" | grep FILEMOUNT | grep "sites/default/files" -lando ssh -c "env" | grep PANTHEON_ENVIRONMENT | grep lando -lando ssh -c "env" | grep PANTHEON_INDEX_HOST | grep index -lando ssh -c "env" | grep PANTHEON_INDEX_PORT | grep 449 -lando ssh -c "env" | grep PANTHEON_SITE | grep 6e8d4bb2-dd6f-4640-9d12-d95a942c34ca -lando ssh -c "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal7 -lando ssh -c "env" | grep php_version | grep "7.4" -lando ssh -c "env" | grep PRESSFLOW_SETTINGS | grep pantheon -lando ssh -c "env" | grep TERMINUS_ENV | grep dev -lando ssh -c "env" | grep TERMINUS_SITE | grep landobot-drupal7 -lando ssh -c "env" | grep TERMINUS_USER | grep droid@lando.dev +lando exec appserver -- env | grep BACKDROP_SETTINGS | grep pantheon +lando exec appserver -- env | grep CACHE_HOST | grep cache +lando exec appserver -- env | grep CACHE_PORT | grep 6379 +lando exec appserver -- env | grep DB_HOST | grep database +lando exec appserver -- env | grep DB_PORT | grep 3306 +lando exec appserver -- env | grep DB_USER | grep pantheon +lando exec appserver -- env | grep DB_PASSWORD | grep pantheon +lando exec appserver -- env | grep DB_NAME | grep pantheon +lando exec appserver -- env | grep FRAMEWORK | grep drupal +lando exec appserver -- env | grep FILEMOUNT | grep "sites/default/files" +lando exec appserver -- env | grep PANTHEON_ENVIRONMENT | grep lando +lando exec appserver -- env | grep PANTHEON_INDEX_HOST | grep index +lando exec appserver -- env | grep PANTHEON_INDEX_PORT | grep 449 +lando exec appserver -- env | grep PANTHEON_SITE | grep 6e8d4bb2-dd6f-4640-9d12-d95a942c34ca +lando exec appserver -- env | grep PANTHEON_SITE_NAME | grep landobot-drupal7 +lando exec appserver -- env | grep php_version | grep "7.4" +lando exec appserver -- env | grep PRESSFLOW_SETTINGS | grep pantheon +lando exec appserver -- env | grep TERMINUS_ENV | grep dev +lando exec appserver -- env | grep TERMINUS_SITE | grep landobot-drupal7 +lando exec appserver -- env | grep TERMINUS_USER | grep droid@lando.dev # Should not set any 8983 perms cd drupal7 -lando ssh -c "ls -ls /app" | grep "8983" || echo $? | grep 1 +lando exec appserver -- "ls -ls /app" | grep "8983" || echo $? | grep 1 # Should be running from the root directory by default cd drupal7 -lando ssh -s appserver -c "curl -kL https://edge_ssl" | grep "Drupal 7 for Lando" -lando ssh -s appserver -c "curl -L http://edge" | grep "Drupal 7 for Lando" -lando ssh -s appserver -c "env" | grep "LANDO_WEBROOT=/app" +lando exec appserver -- "curl -L https://edge_ssl" | grep "Drupal 7 for Lando" +lando exec appserver -- "curl -L http://edge" | grep "Drupal 7 for Lando" +lando exec appserver -- "env" | grep "LANDO_WEBROOT=/app" # Should use php version 7.4 by default for drupal7 sites cd drupal7 @@ -125,11 +125,11 @@ lando php -m | grep xdebug || echo $? | grep 1 # Should be running nginx 1.25 cd drupal7 -lando ssh -s appserver_nginx -c "/opt/bitnami/nginx/sbin/nginx -v 2>&1 | grep 1.25" +lando exec appserver_nginx -- "/opt/bitnami/nginx/sbin/nginx -v 2>&1 | grep 1.25" # Should have a running solr instance cd drupal7 -lando ssh -s appserver -c "curl https://index:449/sites/self/environments/lando/index/admin/" +lando exec appserver -- "curl https://index:449/sites/self/environments/lando/index/admin/" # Should use a varnish http_resp_hdr_len setting of 25k cd drupal7 @@ -138,7 +138,7 @@ lando varnishadm param.show http_resp_hdr_len | grep 'Value is: 25k' # Should be able to push commits to pantheon cd drupal7 lando pull --code dev --database none --files none -lando ssh -s appserver -c "git rev-parse HEAD > test.log" +lando exec appserver -- "git rev-parse HEAD > test.log" lando push --code dev --database none --files none --message "Testing commit $(git rev-parse HEAD)" || true # Should allow code pull from protected environments @@ -157,7 +157,7 @@ Run the following commands to trash this app like nothing ever happened. # Should be able to remove our pantheon ssh keys cp -r remove-keys.sh drupal7/remove-keys.sh cd drupal7 -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" cd .. rm -rf drupal7/remove-keys.sh diff --git a/examples/drupal8/README.md b/examples/drupal8/README.md index 40692c5..7a410b9 100644 --- a/examples/drupal8/README.md +++ b/examples/drupal8/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test drupal8 site rm -rf drupal8 && mkdir -p drupal8 && cd drupal8 +lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-drupal8 --option composer_version=2 cp ../../.lando.upstream.yml .lando.upstream.yml -lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-drupal8 --option composer_version=1.10.1 # Should start up our drupal8 site successfully cd drupal8 @@ -46,7 +46,7 @@ lando drush version | grep 10. # Should use MariaDB 10.3 cd drupal8 -lando ssh -s database -c "mysql -V" | grep 10.4. +lando exec database -- "mysql -V" | grep 10.4. # Should be able to export DB cd drupal8 @@ -66,31 +66,31 @@ lando terminus auth:whoami | grep droid@lando.dev # Should have a binding.pem in all the right places cd drupal8 -lando ssh -s appserver -c "stat /var/www/certs/binding.pem" -lando ssh -s appserver -u root -c "stat /root/certs/binding.pem" +lando exec appserver -- "stat /var/www/certs/binding.pem" +lando exec appserver -u root -- "stat /root/certs/binding.pem" # Should set the correct pantheon environment cd drupal8 -lando ssh -c "env" | grep BACKDROP_SETTINGS | grep pantheon -lando ssh -c "env" | grep CACHE_HOST | grep cache -lando ssh -c "env" | grep CACHE_PORT | grep 6379 -lando ssh -c "env" | grep DB_HOST | grep database -lando ssh -c "env" | grep DB_PORT | grep 3306 -lando ssh -c "env" | grep DB_USER | grep pantheon -lando ssh -c "env" | grep DB_PASSWORD | grep pantheon -lando ssh -c "env" | grep DB_NAME | grep pantheon -lando ssh -c "env" | grep FRAMEWORK | grep drupal8 -lando ssh -c "env" | grep FILEMOUNT | grep "sites/default/files" -lando ssh -c "env" | grep PANTHEON_ENVIRONMENT | grep lando -lando ssh -c "env" | grep PANTHEON_INDEX_HOST | grep index -lando ssh -c "env" | grep PANTHEON_INDEX_PORT | grep 449 -lando ssh -c "env" | grep PANTHEON_SITE | grep 0831109d-10e9-426a-845a-e8396554acfa -lando ssh -c "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal8 -lando ssh -c "env" | grep php_version | grep "7.4" -lando ssh -c "env" | grep PRESSFLOW_SETTINGS | grep pantheon -lando ssh -c "env" | grep TERMINUS_ENV | grep dev -lando ssh -c "env" | grep TERMINUS_SITE | grep landobot-drupal8 -lando ssh -c "env" | grep TERMINUS_USER | grep droid@lando.dev +lando exec appserver -- "env" | grep BACKDROP_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep CACHE_HOST | grep cache +lando exec appserver -- "env" | grep CACHE_PORT | grep 6379 +lando exec appserver -- "env" | grep DB_HOST | grep database +lando exec appserver -- "env" | grep DB_PORT | grep 3306 +lando exec appserver -- "env" | grep DB_USER | grep pantheon +lando exec appserver -- "env" | grep DB_PASSWORD | grep pantheon +lando exec appserver -- "env" | grep DB_NAME | grep pantheon +lando exec appserver -- "env" | grep FRAMEWORK | grep drupal8 +lando exec appserver -- "env" | grep FILEMOUNT | grep "sites/default/files" +lando exec appserver -- "env" | grep PANTHEON_ENVIRONMENT | grep lando +lando exec appserver -- "env" | grep PANTHEON_INDEX_HOST | grep index +lando exec appserver -- "env" | grep PANTHEON_INDEX_PORT | grep 449 +lando exec appserver -- "env" | grep PANTHEON_SITE | grep 0831109d-10e9-426a-845a-e8396554acfa +lando exec appserver -- "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal8 +lando exec appserver -- "env" | grep php_version | grep "7.4" +lando exec appserver -- "env" | grep PRESSFLOW_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep TERMINUS_ENV | grep dev +lando exec appserver -- "env" | grep TERMINUS_SITE | grep landobot-drupal8 +lando exec appserver -- "env" | grep TERMINUS_USER | grep droid@lando.dev # Should use php version in pantheon.upstream.yml cd drupal8 @@ -112,7 +112,7 @@ lando php -m | grep xdebug || echo $? | grep 1 # Should be able to push commits to pantheon cd drupal8 lando pull --code dev --database none --files none -lando ssh -s appserver -c "git rev-parse HEAD > test.log" +lando exec appserver -- "git rev-parse HEAD > test.log" lando push --code dev --database none --files none --message "Testing commit $(git rev-parse HEAD)" # Should allow code pull from protected environments @@ -130,10 +130,10 @@ Destroy tests Run the following commands to trash this app like nothing ever happened. ```bash -# Should be able to remove our pantheon ssh keys +# Should be able to remove our pantheon exec appserver keys cp -r remove-keys.sh drupal8/remove-keys.sh cd drupal8 -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" cd .. rm -rf drupal8/remove-keys.sh diff --git a/examples/drupal9/README.md b/examples/drupal9/README.md index 3187cf3..d6d7ec5 100644 --- a/examples/drupal9/README.md +++ b/examples/drupal9/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test drupal9 site rm -rf drupal9 && mkdir -p drupal9 && cd drupal9 -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-drupal9 +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our drupal9 site successfully cd drupal9 @@ -54,34 +54,34 @@ lando terminus auth:whoami | grep droid@lando.dev # Should have a binding.pem in all the right places cd drupal9 -lando ssh -s appserver -c "stat /var/www/certs/binding.pem" -lando ssh -s appserver -u root -c "stat /root/certs/binding.pem" +lando exec appserver -- "stat /var/www/certs/binding.pem" +lando exec appserver -u root -- "stat /root/certs/binding.pem" # Should set the correct pantheon environment cd drupal9 -lando ssh -c "env" | grep BACKDROP_SETTINGS | grep pantheon -lando ssh -c "env" | grep CACHE_HOST | grep cache -lando ssh -c "env" | grep CACHE_PORT | grep 6379 -lando ssh -c "env" | grep DB_HOST | grep database -lando ssh -c "env" | grep DB_PORT | grep 3306 -lando ssh -c "env" | grep DB_USER | grep pantheon -lando ssh -c "env" | grep DB_PASSWORD | grep pantheon -lando ssh -c "env" | grep DB_NAME | grep pantheon -lando ssh -c "env" | grep FRAMEWORK | grep drupal8 -lando ssh -c "env" | grep FILEMOUNT | grep "sites/default/files" -lando ssh -c "env" | grep PANTHEON_ENVIRONMENT | grep lando -lando ssh -c "env" | grep PANTHEON_INDEX_CORE | grep "\/lando" -lando ssh -c "env" | grep PANTHEON_INDEX_HOST | grep index -lando ssh -c "env" | grep PANTHEON_INDEX_PORT | grep 8983 -lando ssh -c "env" | grep PANTHEON_INDEX_SCHEMA | grep "solr\/#\/lando\/schema" -lando ssh -c "env" | grep PANTHEON_INDEX_SCHEME | grep http -lando ssh -c "env" | grep PANTHEON_SITE | grep 3a225571-2a52-4ae9-84e7-ef54037ac66c -lando ssh -c "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal9 -lando ssh -c "env" | grep php_version | grep "8" -lando ssh -c "env" | grep PRESSFLOW_SETTINGS | grep pantheon -lando ssh -c "env" | grep TERMINUS_ENV | grep dev -lando ssh -c "env" | grep TERMINUS_SITE | grep landobot-drupal9 -lando ssh -c "env" | grep TERMINUS_USER | grep droid@lando.dev +lando exec appserver -- "env" | grep BACKDROP_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep CACHE_HOST | grep cache +lando exec appserver -- "env" | grep CACHE_PORT | grep 6379 +lando exec appserver -- "env" | grep DB_HOST | grep database +lando exec appserver -- "env" | grep DB_PORT | grep 3306 +lando exec appserver -- "env" | grep DB_USER | grep pantheon +lando exec appserver -- "env" | grep DB_PASSWORD | grep pantheon +lando exec appserver -- "env" | grep DB_NAME | grep pantheon +lando exec appserver -- "env" | grep FRAMEWORK | grep drupal8 +lando exec appserver -- "env" | grep FILEMOUNT | grep "sites/default/files" +lando exec appserver -- "env" | grep PANTHEON_ENVIRONMENT | grep lando +lando exec appserver -- "env" | grep PANTHEON_INDEX_CORE | grep "\/lando" +lando exec appserver -- "env" | grep PANTHEON_INDEX_HOST | grep index +lando exec appserver -- "env" | grep PANTHEON_INDEX_PORT | grep 8983 +lando exec appserver -- "env" | grep PANTHEON_INDEX_SCHEMA | grep "solr\/#\/lando\/schema" +lando exec appserver -- "env" | grep PANTHEON_INDEX_SCHEME | grep http +lando exec appserver -- "env" | grep PANTHEON_SITE | grep 3a225571-2a52-4ae9-84e7-ef54037ac66c +lando exec appserver -- "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal9 +lando exec appserver -- "env" | grep php_version | grep "8" +lando exec appserver -- "env" | grep PRESSFLOW_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep TERMINUS_ENV | grep dev +lando exec appserver -- "env" | grep TERMINUS_SITE | grep landobot-drupal9 +lando exec appserver -- "env" | grep TERMINUS_USER | grep droid@lando.dev # Should use php version in pantheon.upstream.yml cd drupal9 @@ -89,15 +89,15 @@ lando php -v | grep "PHP 8.1" # Should use the database version in pantheon.yml cd drupal9 -lando ssh -s database -c "mysql -V" | grep 10.6. +lando exec database -- "mysql -V" | grep 10.6. # Should use the solr version in pantheon.yml cd drupal9 -lando ssh -c "curl http://index:8983/solr/admin/info/system" | grep "\"solr-spec-version\":\"8.8.2\"" +lando exec appserver -- "curl http://index:8983/solr/admin/info/system" | grep "\"solr-spec-version\":\"8.8.2\"" # Jetty redirects should work for Pantheon Search cd drupal9 -lando ssh -c "curl http://index:8983/lando/v1/lando/admin/system" | grep "\"solr-spec-version\":\"8.8.2\"" +lando exec appserver -- "curl http://index:8983/lando/v1/lando/admin/system" | grep "\"solr-spec-version\":\"8.8.2\"" # Should use a varnish http_resp_hdr_len setting of 25k cd drupal9 @@ -115,7 +115,7 @@ lando php -m | grep xdebug || echo $? | grep 1 # Should be able to push commits to pantheon cd drupal9 lando pull --code dev --database none --files none -lando ssh -s appserver -c "git rev-parse HEAD > test.log" +lando exec appserver -- "git rev-parse HEAD > test.log" lando push --code dev --database none --files none --message "Testing commit $(git rev-parse HEAD)" # Should allow code pull from protected environments @@ -137,7 +137,7 @@ Run the following commands to trash this app like nothing ever happened. # Should be able to remove our pantheon ssh keys cp -r remove-keys.sh drupal9/remove-keys.sh cd drupal9 -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" cd .. rm -rf drupal9/remove-keys.sh diff --git a/examples/init/README.md b/examples/init/README.md index 54fbcb6..65874da 100644 --- a/examples/init/README.md +++ b/examples/init/README.md @@ -20,8 +20,8 @@ lando poweroff rm -rf drupal9 git clone https://github.com/lando/pantheon-gitpod.git drupal9 cd drupal9 -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source cwd --recipe pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-drupal9 +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our drupal9 site successfully cd drupal9 @@ -56,31 +56,31 @@ lando terminus auth:whoami | grep droid@lando.dev # Should have a binding.pem in all the right places cd drupal9 -lando ssh -s appserver -c "stat /var/www/certs/binding.pem" -lando ssh -s appserver -u root -c "stat /root/certs/binding.pem" +lando exec appserver -- "stat /var/www/certs/binding.pem" +lando exec appserver -u root -- "stat /root/certs/binding.pem" # Should set the correct pantheon environment cd drupal9 -lando ssh -c "env" | grep BACKDROP_SETTINGS | grep pantheon -lando ssh -c "env" | grep CACHE_HOST | grep cache -lando ssh -c "env" | grep CACHE_PORT | grep 6379 -lando ssh -c "env" | grep DB_HOST | grep database -lando ssh -c "env" | grep DB_PORT | grep 3306 -lando ssh -c "env" | grep DB_USER | grep pantheon -lando ssh -c "env" | grep DB_PASSWORD | grep pantheon -lando ssh -c "env" | grep DB_NAME | grep pantheon -lando ssh -c "env" | grep FRAMEWORK | grep drupal8 -lando ssh -c "env" | grep FILEMOUNT | grep "sites/default/files" -lando ssh -c "env" | grep PANTHEON_ENVIRONMENT | grep lando -lando ssh -c "env" | grep PANTHEON_INDEX_HOST | grep index -lando ssh -c "env" | grep PANTHEON_INDEX_PORT | grep 449 -lando ssh -c "env" | grep PANTHEON_SITE | grep 3a225571-2a52-4ae9-84e7-ef54037ac66c -lando ssh -c "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal9 -lando ssh -c "env" | grep php_version | grep "8" -lando ssh -c "env" | grep PRESSFLOW_SETTINGS | grep pantheon -lando ssh -c "env" | grep TERMINUS_ENV | grep dev -lando ssh -c "env" | grep TERMINUS_SITE | grep landobot-drupal9 -lando ssh -c "env" | grep TERMINUS_USER | grep droid@lando.dev +lando exec appserver -- "env" | grep BACKDROP_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep CACHE_HOST | grep cache +lando exec appserver -- "env" | grep CACHE_PORT | grep 6379 +lando exec appserver -- "env" | grep DB_HOST | grep database +lando exec appserver -- "env" | grep DB_PORT | grep 3306 +lando exec appserver -- "env" | grep DB_USER | grep pantheon +lando exec appserver -- "env" | grep DB_PASSWORD | grep pantheon +lando exec appserver -- "env" | grep DB_NAME | grep pantheon +lando exec appserver -- "env" | grep FRAMEWORK | grep drupal8 +lando exec appserver -- "env" | grep FILEMOUNT | grep "sites/default/files" +lando exec appserver -- "env" | grep PANTHEON_ENVIRONMENT | grep lando +lando exec appserver -- "env" | grep PANTHEON_INDEX_HOST | grep index +lando exec appserver -- "env" | grep PANTHEON_INDEX_PORT | grep 449 +lando exec appserver -- "env" | grep PANTHEON_SITE | grep 3a225571-2a52-4ae9-84e7-ef54037ac66c +lando exec appserver -- "env" | grep PANTHEON_SITE_NAME | grep landobot-drupal9 +lando exec appserver -- "env" | grep php_version | grep "8" +lando exec appserver -- "env" | grep PRESSFLOW_SETTINGS | grep pantheon +lando exec appserver -- "env" | grep TERMINUS_ENV | grep dev +lando exec appserver -- "env" | grep TERMINUS_SITE | grep landobot-drupal9 +lando exec appserver -- "env" | grep TERMINUS_USER | grep droid@lando.dev # Should use php version in pantheon.upstream.yml cd drupal9 diff --git a/examples/pantheon-downstreamer-1/README.md b/examples/pantheon-downstreamer-1/README.md index 2b5d838..48551ba 100644 --- a/examples/pantheon-downstreamer-1/README.md +++ b/examples/pantheon-downstreamer-1/README.md @@ -28,7 +28,7 @@ lando ssh -s database -c "mysql -V" | grep 10.6. lando mysql pantheon -e quit # Should use the default mysql config file -lando ssh -s database -c "cat /opt/bitnami/mariadb/conf/my_custom.cnf" | grep "LANDOPANTHEONMYSQLCNF" +lando exec database -- "cat /opt/bitnami/mariadb/conf/my_custom.cnf" | grep "LANDOPANTHEONMYSQLCNF" lando mysql -u root -e "show variables;" | grep innodb_lock_wait_timeout | grep 121 ``` diff --git a/examples/pantheon-downstreamer-2/README.md b/examples/pantheon-downstreamer-2/README.md index 28ac4e3..bb7751c 100644 --- a/examples/pantheon-downstreamer-2/README.md +++ b/examples/pantheon-downstreamer-2/README.md @@ -22,13 +22,13 @@ Run the following commands to validate things are rolling as they should. ```bash # Should use mariadb 10.6 -lando ssh -s database -c "mysql -V" | grep 10.6. +lando exec database -- "mysql -V" | grep 10.6. # Should be able to connect to the pantheon db. lando mysql pantheon -e quit # Should use the default mysql config file -lando ssh -s database -c "cat /opt/bitnami/mariadb/conf/my_custom.cnf" | grep "LANDOPANTHEONMYSQLCNF" +lando exec database -- "cat /opt/bitnami/mariadb/conf/my_custom.cnf" | grep "LANDOPANTHEONMYSQLCNF" lando mysql -u root -e "show variables;" | grep innodb_lock_wait_timeout | grep 121 # Should portforward DB by default. diff --git a/examples/wordpress/README.md b/examples/wordpress/README.md index 21e5485..97eb947 100644 --- a/examples/wordpress/README.md +++ b/examples/wordpress/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test wordpress site rm -rf wordpress && mkdir -p wordpress && cd wordpress -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-wordpress --option composer_version=1.10.1 +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our wordpress site successfully cd wordpress @@ -46,13 +46,13 @@ lando wp cli version # Should use custom webroot when set in pantheon.yml cd wordpress -lando ssh -s appserver -c "curl -L http://appserver_nginx" | grep "WordPress for Lando" -lando ssh -s appserver -c "curl -kL https://appserver_nginx" | grep "WordPress for Lando" -lando ssh -s appserver -c "env" | grep "LANDO_WEBROOT=/app/web" +lando exec appserver -- "curl -L http://appserver_nginx" | grep "WordPress for Lando" +lando exec appserver -- "curl -kL https://appserver_nginx" | grep "WordPress for Lando" +lando exec appserver -- "env" | grep "LANDO_WEBROOT=/app/web" # Should set /var/www/.wp-cli/config.yml with LANDO_WEBROOT as PATH cd wordpress -lando ssh -s appserver -c "cat /var/www/.wp-cli/config.yml | grep path | grep /app/web" +lando exec appserver -- "cat /var/www/.wp-cli/config.yml | grep path | grep /app/web" # Should have terminus cd wordpress @@ -72,8 +72,8 @@ lando php -v | grep "PHP 7.3" # Should set the correct wordpress specific pantheon environment cd wordpress -lando ssh -c "env" | grep FRAMEWORK | grep wordpress -lando ssh -c "env" | grep FILEMOUNT | grep "wp-content/uploads" +lando exec appserver -- "env" | grep FRAMEWORK | grep wordpress +lando exec appserver -- "env" | grep FILEMOUNT | grep "wp-content/uploads" # Should disable edge, index or cache containers and tools when specified docker ps --filter label=com.docker.compose.project=landobotwordpress | grep landobotwordpress_appserver_nginx_1 @@ -95,20 +95,20 @@ curl -LI http://landobot-wordress.lndo.site | grep Via || echo $? | grep 1 # Should have phantomjs 1.7.0 installed at /srv/bin/phantomjs cd wordpress -lando ssh -s appserver -c "/srv/bin/phantomjs --version" | grep "1.7.0" +lando exec appserver -- "/srv/bin/phantomjs --version" | grep "1.7.0" # Should have apache tika1.18 installed /srv/bin/tika-app-1.18.jar cd wordpress -lando ssh -s appserver -c "java -jar /srv/bin/tika-app-1.1.jar --version" | grep "Apache Tika 1.1" +lando exec appserver -- "java -jar /srv/bin/tika-app-1.1.jar --version" | grep "Apache Tika 1.1" # Should have wkhtmltopdf installed at /srv/bin/wkhtmltopdf cd wordpress -lando ssh -s appserver -c "/srv/bin/wkhtmltopdf --version" +lando exec appserver -- "/srv/bin/wkhtmltopdf --version" # Should be able to push commits to pantheon cd wordpress lando pull --code dev --database none --files none -lando ssh -s appserver -c "git rev-parse HEAD > test.log" +lando exec appserver -- "git rev-parse HEAD > test.log" lando push --code dev --database none --files none --message "Testing commit $(git rev-parse HEAD)" # Should allow code pull from protected environments @@ -127,7 +127,7 @@ Run the following commands to trash this app like nothing ever happened. # Should be able to remove our pantheon ssh keys cp -r remove-keys.sh wordpress/remove-keys.sh cd wordpress -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" rm -rf wordpress/remove-keys.sh # Should be able to destroy our wordpress site with success diff --git a/examples/wordpressnetworkdomain/README.md b/examples/wordpressnetworkdomain/README.md index 9f425a6..e53e3ff 100644 --- a/examples/wordpressnetworkdomain/README.md +++ b/examples/wordpressnetworkdomain/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test wordpress site rm -rf wordpress && mkdir -p wordpress && cd wordpress -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-network-domain +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our wordpress site successfully cd wordpress @@ -46,7 +46,7 @@ lando wp cli version # Should set /var/www/.wp-cli/config.yml with LANDO_WEBROOT as PATH cd wordpress -lando ssh -s appserver -c "cat /var/www/.wp-cli/config.yml | grep path | grep /app" +lando exec appserver -- "cat /var/www/.wp-cli/config.yml | grep path | grep /app" # Should have terminus cd wordpress @@ -62,8 +62,8 @@ lando php -v | grep "PHP 7.3" # Should set the correct wordpress specific pantheon environment cd wordpress -lando ssh -c "env" | grep FRAMEWORK | grep wordpress_network -lando ssh -c "env" | grep FILEMOUNT | grep "wp-content/uploads" +lando exec appserver -- "env" | grep FRAMEWORK | grep wordpress_network +lando exec appserver -- "env" | grep FILEMOUNT | grep "wp-content/uploads" # Should disable edge, index or cache containers and tools when specified docker ps --filter label=com.docker.compose.project=landobotnetworkdomain | grep landobotnetworkdomain_appserver_nginx_1 @@ -90,7 +90,7 @@ Run the following commands to trash this app like nothing ever happened. # Should be able to remove our pantheon ssh keys cp -r remove-keys.sh wordpress/remove-keys.sh cd wordpress -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" rm -rf wordpress/remove-keys.sh # Should be able to destroy our wordpress site with success diff --git a/examples/wordpressnetworkfolder/README.md b/examples/wordpressnetworkfolder/README.md index f21f49e..1e4deaa 100644 --- a/examples/wordpressnetworkfolder/README.md +++ b/examples/wordpressnetworkfolder/README.md @@ -18,8 +18,8 @@ lando poweroff # Should initialize the lando pantheon test wordpress site rm -rf wordpress && mkdir -p wordpress && cd wordpress -cp ../../.lando.upstream.yml .lando.upstream.yml lando init --source pantheon --pantheon-auth "$PANTHEON_MACHINE_TOKEN" --pantheon-site landobot-network-folder +cp ../../.lando.upstream.yml .lando.upstream.yml # Should start up our wordpress site successfully cd wordpress @@ -46,7 +46,7 @@ lando wp cli version # Should set /var/www/.wp-cli/config.yml with LANDO_WEBROOT as PATH cd wordpress -lando ssh -s appserver -c "cat /var/www/.wp-cli/config.yml | grep path | grep /app" +lando exec appserver -- "cat /var/www/.wp-cli/config.yml | grep path | grep /app" # Should have terminus cd wordpress @@ -62,8 +62,8 @@ lando php -v | grep "PHP 7.3" # Should set the correct wordpress specific pantheon environment cd wordpress -lando ssh -c "env" | grep FRAMEWORK | grep wordpress -lando ssh -c "env" | grep FILEMOUNT | grep "wp-content/uploads" +lando exec -- "env" | grep FRAMEWORK | grep wordpress +lando exec -- "env" | grep FILEMOUNT | grep "wp-content/uploads" # Should serve proxy from nginx cd wordpress @@ -82,7 +82,7 @@ Run the following commands to trash this app like nothing ever happened. # Should be able to remove our pantheon ssh keys cp -r remove-keys.sh wordpress/remove-keys.sh cd wordpress -lando ssh -s appserver -c "/app/remove-keys.sh" +lando exec appserver -- "/app/remove-keys.sh" rm -rf wordpress/remove-keys.sh # Should be able to destroy our wordpress site with success diff --git a/lib/utils.js b/lib/utils.js index 4f9e063..ea7aedf 100644 --- a/lib/utils.js +++ b/lib/utils.js @@ -220,6 +220,8 @@ exports.getPantheonEnvironment = options => ({ drush_version: options.drush_version, FRAMEWORK: options.framework, FILEMOUNT: getFilemount(options.framework), + LANDO_SERVICE_CERT: '/certs/cert.crt', + LANDO_SERVICE_KEY: '/certs/cert.key', LOGGED_IN_KEY: getHash(options.app), LOGGED_IN_SALT: getHash(options.root + options.app), NONCE_SALT: getHash(options.root + options.root), diff --git a/scripts/binding.sh b/scripts/binding.sh index ed9f303..c859c47 100755 --- a/scripts/binding.sh +++ b/scripts/binding.sh @@ -8,3 +8,4 @@ fi # We need this because windows runs FPM as root to handle file permission issues mkdir -p /root/certs ln -sfn /var/www/certs/binding.pem /root/certs/binding.pem +ln -sfn /var/www/certs/binding.pem /certs/binding.pem diff --git a/scripts/pantheon.sh b/scripts/pantheon.sh index 74d7015..b1e9f06 100755 --- a/scripts/pantheon.sh +++ b/scripts/pantheon.sh @@ -11,17 +11,21 @@ LANDO_MODULE="pantheon" # Kick it off lando_pink "Pantheon pre-run scripting" -/helpers/add-cert.sh --silent - # Set up some new dirs +mkdir -p /certs mkdir -p /var/www/certs mkdir -p /srv/bindings -chown -R www-data:www-data /var/www/certs /srv/bindings +chown -R www-data:www-data /var/www/certs /srv/bindings /certs + +# copy over appservernginx certs to work around 3.22 cert changes +cp -rf "/lando/certs/appserver_nginx.${LANDO_APP_PROJECT}.crt" /certs/cert.crt +cp -rf "/lando/certs/appserver_nginx.${LANDO_APP_PROJECT}.key" /certs/cert.key + +# run through add cert +/helpers/add-cert.sh --silent # Set up some symlnks ln -sfn /var/www /srv/bindings/lando -ln -sfn /var/www/certs/binding.pem /certs/binding.pem - ln -sfn /tmp /srv/bindings/lando/tmp ln -sfn /app /srv/bindings/lando/code ln -sfn /app /code