From f383789824a9890f9d5c5e2d51a9a5b0f9b0f9ab Mon Sep 17 00:00:00 2001 From: Alex Skrypnyk Date: Thu, 26 Sep 2024 18:15:03 +1000 Subject: [PATCH] [#1398] Renamed `.env.local.default` to `.env.local.example`. --- .env | 2 +- .env.local.default => .env.local.example | 0 .vortex/docs/.utils/update-docs.sh | 4 +-- .../variables/variables.inline-code-extra.txt | 2 +- .../content/getting-started/architecture.mdx | 2 +- .vortex/docs/content/workflows/variables.mdx | 26 +++++++++---------- .../installer/src/Command/InstallCommand.php | 2 +- .vortex/tests/bats/_helper.bash | 24 ++++++++--------- .vortex/tests/bats/docker-compose.bats | 2 +- README.dist.md | 4 +-- 10 files changed, 34 insertions(+), 34 deletions(-) rename .env.local.default => .env.local.example (100%) diff --git a/.env b/.env index bc217c606..b8e59a4e3 100644 --- a/.env +++ b/.env @@ -12,7 +12,7 @@ # To apply any changes made to this file, run `docker-compose up cli -d` or # `ahoy up cli`. # -# To customize variables locally, copy `.env.local.default` to `.env.local`. +# To customize variables locally, copy `.env.local.example` to `.env.local`. # # @see https://vortex.drevops.com/workflows/variables diff --git a/.env.local.default b/.env.local.example similarity index 100% rename from .env.local.default rename to .env.local.example diff --git a/.vortex/docs/.utils/update-docs.sh b/.vortex/docs/.utils/update-docs.sh index 8a311a0ec..7be6e328f 100755 --- a/.vortex/docs/.utils/update-docs.sh +++ b/.vortex/docs/.utils/update-docs.sh @@ -36,7 +36,7 @@ echo >>"${OUTPUT_FILE}" --md-block-template-file=./.utils/variables/variables.template.md \ --path-strip-prefix="${ROOT_DIR}/" \ ../../.env \ - ../../.env.local.default \ + ../../.env.local.example \ ./.utils/variables/extra \ ../../scripts/vortex \ ../../scripts/custom \ @@ -45,7 +45,7 @@ echo >>"${OUTPUT_FILE}" sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/environment.variables.sh/ENVIRONMENT/g" "${OUTPUT_FILE}" sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/acquia.variables.sh/ACQUIA ENVIRONMENT/g" "${OUTPUT_FILE}" sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/lagoon.variables.sh/LAGOON ENVIRONMENT/g" "${OUTPUT_FILE}" -sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/.env.local.default.variables.sh/.env.local.default/g" "${OUTPUT_FILE}" +sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/.env.local.example.variables.sh/.env.local.example/g" "${OUTPUT_FILE}" sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/.env.variables.sh/.env/g" "${OUTPUT_FILE}" sed "${sed_opts[@]}" "s/.vortex\/docs\/.utils\/variables\/extra\/ci.variables.sh/CI config/g" "${OUTPUT_FILE}" diff --git a/.vortex/docs/.utils/variables/variables.inline-code-extra.txt b/.vortex/docs/.utils/variables/variables.inline-code-extra.txt index da2930edb..81e34bf03 100755 --- a/.vortex/docs/.utils/variables/variables.inline-code-extra.txt +++ b/.vortex/docs/.utils/variables/variables.inline-code-extra.txt @@ -5,4 +5,4 @@ drevops/drevops-mariadb-drupal-data .ahoy.local.example.yml .env .env.local -.env.local.default +.env.local.example diff --git a/.vortex/docs/content/getting-started/architecture.mdx b/.vortex/docs/content/getting-started/architecture.mdx index 7b4252e59..37478457e 100644 --- a/.vortex/docs/content/getting-started/architecture.mdx +++ b/.vortex/docs/content/getting-started/architecture.mdx @@ -74,7 +74,7 @@ with addition of several configuration files and directories. ├── .dockerignore # Docker ignore configuration file. ├── .editorconfig # Helps maintain consistent coding styles. ├── .env # Environment variables to control project workflow using variables. -├── .env.local.default # Environment variables local overrides. +├── .env.local.example # Environment variables local overrides. ├── .gitignore # Intentionally untracked files to ignore in Git. ├── .gitignore.artifact # Intentionally untracked files to ignore in artifact deployment. ├── .lagoon.yml # Lagoon configuration file. Removed if not using Lagoon hosting. diff --git a/.vortex/docs/content/workflows/variables.mdx b/.vortex/docs/content/workflows/variables.mdx index 0337cbb53..3135b9916 100644 --- a/.vortex/docs/content/workflows/variables.mdx +++ b/.vortex/docs/content/workflows/variables.mdx @@ -22,7 +22,7 @@ Set to `y` to suppress Ahoy prompts. Default value: `UNDEFINED` -Defined in: `.env.local.default` +Defined in: `.env.local.example` ### `AHOY_CONFIRM_WAIT_SKIP` @@ -30,7 +30,7 @@ When Ahoy prompts are suppressed ([`$AHOY_CONFIRM_RESPONSE`](#ahoy_confirm_respo Default value: `1` -Defined in: `.env.local.default` +Defined in: `.env.local.example` ### `COMPOSE_PROJECT_NAME` @@ -182,7 +182,7 @@ GitHub token used to overcome API rate limits or access private repositories.
Override only if you need to use a different URL tha Default value: `.docker.amazee.io` -Defined in: `.env.local.default`, `scripts/vortex/info.sh` +Defined in: `.env.local.example`, `scripts/vortex/info.sh` ### `VORTEX_MIRROR_CODE_BRANCH_DST` @@ -1491,7 +1491,7 @@ Usually set to `0` in deployed environments and can be temporary set to `1` for< Default value: `UNDEFINED` -Defined in: `.env`, `.env.local.default`, `scripts/vortex/provision.sh` +Defined in: `.env`, `.env.local.example`, `scripts/vortex/provision.sh` ### `VORTEX_PROVISION_POST_OPERATIONS_SKIP` diff --git a/.vortex/installer/src/Command/InstallCommand.php b/.vortex/installer/src/Command/InstallCommand.php index 7a358da8d..45420f203 100644 --- a/.vortex/installer/src/Command/InstallCommand.php +++ b/.vortex/installer/src/Command/InstallCommand.php @@ -235,7 +235,7 @@ protected function copyFiles() { // Special case for .env.local as it may exist. if (!file_exists($dst . '/.env.local')) { - static::copyRecursive($dst . '/.env.local.default', $dst . '/.env.local', 0755, FALSE); + static::copyRecursive($dst . '/.env.local.example', $dst . '/.env.local', 0755, FALSE); } } diff --git a/.vortex/tests/bats/_helper.bash b/.vortex/tests/bats/_helper.bash index d1934c044..e97bb7d0e 100644 --- a/.vortex/tests/bats/_helper.bash +++ b/.vortex/tests/bats/_helper.bash @@ -393,7 +393,7 @@ assert_files_present_vortex() { assert_file_exists ".env" assert_file_not_exists ".gitattributes" assert_file_exists ".ahoy.local.example.yml" - assert_file_exists ".env.local.default" + assert_file_exists ".env.local.example" assert_file_exists ".gitignore" assert_file_exists "behat.yml" assert_file_exists "composer.json" @@ -589,13 +589,13 @@ assert_files_present_provision_use_profile() { assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_CURL_URL" assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_ENVIRONMENT" - assert_file_not_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FORCE" - assert_file_not_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FTP_USER" - assert_file_not_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FTP_PASS" - assert_file_not_contains ".env.local.default" "VORTEX_ACQUIA_KEY" - assert_file_not_contains ".env.local.default" "VORTEX_ACQUIA_SECRET" - assert_file_not_contains ".env.local.default" "VORTEX_CONTAINER_REGISTRY_USER" - assert_file_not_contains ".env.local.default" "VORTEX_CONTAINER_REGISTRY_PASS" + assert_file_not_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FORCE" + assert_file_not_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FTP_USER" + assert_file_not_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FTP_PASS" + assert_file_not_contains ".env.local.example" "VORTEX_ACQUIA_KEY" + assert_file_not_contains ".env.local.example" "VORTEX_ACQUIA_SECRET" + assert_file_not_contains ".env.local.example" "VORTEX_CONTAINER_REGISTRY_USER" + assert_file_not_contains ".env.local.example" "VORTEX_CONTAINER_REGISTRY_PASS" assert_file_exists ".ahoy.yml" assert_file_not_contains ".ahoy.yml" "download-db:" @@ -932,8 +932,8 @@ assert_files_present_integration_ftp() { assert_file_contains ".env" "VORTEX_DB_DOWNLOAD_FTP_FILE=" assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_FTP_USER=" assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_FTP_PASS=" - assert_file_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FTP_USER=" - assert_file_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FTP_PASS=" + assert_file_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FTP_USER=" + assert_file_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FTP_PASS=" popd >/dev/null || exit 1 } @@ -949,8 +949,8 @@ assert_files_present_no_integration_ftp() { assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_FTP_FILE=" assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_FTP_USER=" assert_file_not_contains ".env" "VORTEX_DB_DOWNLOAD_FTP_PASS=" - assert_file_not_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FTP_USER=" - assert_file_not_contains ".env.local.default" "VORTEX_DB_DOWNLOAD_FTP_PASS=" + assert_file_not_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FTP_USER=" + assert_file_not_contains ".env.local.example" "VORTEX_DB_DOWNLOAD_FTP_PASS=" popd >/dev/null || exit 1 } diff --git a/.vortex/tests/bats/docker-compose.bats b/.vortex/tests/bats/docker-compose.bats index 0f50d2604..471c39316 100644 --- a/.vortex/tests/bats/docker-compose.bats +++ b/.vortex/tests/bats/docker-compose.bats @@ -76,7 +76,7 @@ load _helper.bash prepare_docker_compose cp "${ROOT_DIR}/.env" .env - cp "${ROOT_DIR}/.env.local.default" .env.local + cp "${ROOT_DIR}/.env.local.example" .env.local substep "Validate configuration" run docker compose -f docker-compose.yml config diff --git a/README.dist.md b/README.dist.md index 2d2cafb52..ba1e89408 100644 --- a/README.dist.md +++ b/README.dist.md @@ -41,7 +41,7 @@ to Vortex progress. Remove this section once onboarding is finished. - Authenticate with Acquia Cloud API 1. Create your Acquia Cloud API token:
Acquia Cloud UI -> Account -> API tokens -> Create Token - 2. Copy `.env.local.default` to `.env.local`. + 2. Copy `.env.local.example` to `.env.local`. 3. Populate `$VORTEX_ACQUIA_KEY` and `$VORTEX_ACQUIA_SECRET` environment variables in `.env.local` file with values generated in the step above. @@ -51,7 +51,7 @@ to Vortex progress. Remove this section once onboarding is finished. - Authenticate with Lagoon 1. Create an SSH key and add it to your account in the [Lagoon Dashboard](https://ui-lagoon-master.ch.amazee.io/). - 2. Copy `.env.local.default` to `.env.local`. + 2. Copy `.env.local.example` to `.env.local`. 3. Update `$VORTEX_DB_DOWNLOAD_SSH_FILE` environment variable in `.env.local` file with the path to the SSH key.