Skip to content

Commit

Permalink
[#1398] Renamed .env.local.default to .env.local.example.
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexSkrypnyk committed Sep 26, 2024
1 parent d475d38 commit f383789
Show file tree
Hide file tree
Showing 10 changed files with 34 additions and 34 deletions.
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions .vortex/docs/.utils/update-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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 \
Expand All @@ -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}"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ drevops/drevops-mariadb-drupal-data
.ahoy.local.example.yml
.env
.env.local
.env.local.default
.env.local.example
2 changes: 1 addition & 1 deletion .vortex/docs/content/getting-started/architecture.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down
26 changes: 13 additions & 13 deletions .vortex/docs/content/workflows/variables.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ Set to `y` to suppress Ahoy prompts.

Default value: `UNDEFINED`

Defined in: `.env.local.default`
Defined in: `.env.local.example`

### `AHOY_CONFIRM_WAIT_SKIP`

When Ahoy prompts are suppressed ([`$AHOY_CONFIRM_RESPONSE`](#ahoy_confirm_response) is `1`), the command<br />will wait for `3` seconds before proceeding.<br />Set this variable to "`1`" to skip the wait.

Default value: `1`

Defined in: `.env.local.default`
Defined in: `.env.local.example`

### `COMPOSE_PROJECT_NAME`

Expand Down Expand Up @@ -182,7 +182,7 @@ GitHub token used to overcome API rate limits or access private repositories.<br

Default value: `UNDEFINED`

Defined in: `.env.local.default`, `scripts/vortex/github-labels.sh`
Defined in: `.env.local.example`, `scripts/vortex/github-labels.sh`

### `LAGOON_PROJECT`

Expand Down Expand Up @@ -266,15 +266,15 @@ Acquia Cloud API key.

Default value: `UNDEFINED`

Defined in: `.env.local.default`, `scripts/vortex/download-db-acquia.sh`, `scripts/vortex/task-copy-db-acquia.sh`, `scripts/vortex/task-copy-files-acquia.sh`, `scripts/vortex/task-purge-cache-acquia.sh`
Defined in: `.env.local.example`, `scripts/vortex/download-db-acquia.sh`, `scripts/vortex/task-copy-db-acquia.sh`, `scripts/vortex/task-copy-files-acquia.sh`, `scripts/vortex/task-purge-cache-acquia.sh`

### `VORTEX_ACQUIA_SECRET`

Acquia Cloud API secret.

Default value: `UNDEFINED`

Defined in: `.env.local.default`, `scripts/vortex/download-db-acquia.sh`, `scripts/vortex/task-copy-db-acquia.sh`, `scripts/vortex/task-copy-files-acquia.sh`, `scripts/vortex/task-purge-cache-acquia.sh`
Defined in: `.env.local.example`, `scripts/vortex/download-db-acquia.sh`, `scripts/vortex/task-copy-db-acquia.sh`, `scripts/vortex/task-copy-files-acquia.sh`, `scripts/vortex/task-purge-cache-acquia.sh`

### `VORTEX_CI_ARTIFACTS`

Expand Down Expand Up @@ -412,15 +412,15 @@ The password (token) to log into the container registry.

Default value: `${DOCKER_PASS}`

Defined in: `.env.local.default`, `scripts/vortex/login-container-registry.sh`
Defined in: `.env.local.example`, `scripts/vortex/login-container-registry.sh`

### `VORTEX_CONTAINER_REGISTRY_USER`

The username to log into the container registry.

Default value: `${DOCKER_USER}`

Defined in: `.env.local.default`, `scripts/vortex/login-container-registry.sh`
Defined in: `.env.local.example`, `scripts/vortex/login-container-registry.sh`

### `VORTEX_DB_DIR`

Expand Down Expand Up @@ -460,7 +460,7 @@ Always override existing downloaded DB dump.

Default value: `1`

Defined in: `.env.local.default`, `.env.local.default`, `scripts/vortex/download-db.sh`
Defined in: `.env.local.example`, `.env.local.example`, `scripts/vortex/download-db.sh`

### `VORTEX_DB_DOWNLOAD_FTP_FILE`

Expand All @@ -484,7 +484,7 @@ Database dump FTP password.

Default value: `UNDEFINED`

Defined in: `.env.local.default`, `scripts/vortex/download-db-ftp.sh`
Defined in: `.env.local.example`, `scripts/vortex/download-db-ftp.sh`

### `VORTEX_DB_DOWNLOAD_FTP_PORT`

Expand All @@ -500,7 +500,7 @@ Database dump FTP user.

Default value: `UNDEFINED`

Defined in: `.env.local.default`, `scripts/vortex/download-db-ftp.sh`
Defined in: `.env.local.example`, `scripts/vortex/download-db-ftp.sh`

### `VORTEX_DB_DOWNLOAD_LAGOON_REMOTE_DIR`

Expand Down Expand Up @@ -674,7 +674,7 @@ Set to `1` to print debug information in Vortex scripts.

Default value: `UNDEFINED`

Defined in: `.env.local.default`
Defined in: `.env.local.example`

### `VORTEX_DEPLOY_ACTION`

Expand Down Expand Up @@ -1083,7 +1083,7 @@ Local development URL.<br />Override only if you need to use a different URL tha

Default value: `<current_dir>.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`

Expand Down Expand Up @@ -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`

Expand Down
2 changes: 1 addition & 1 deletion .vortex/installer/src/Command/InstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -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);
}
}

Expand Down
24 changes: 12 additions & 12 deletions .vortex/tests/bats/_helper.bash
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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:"
Expand Down Expand Up @@ -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
}
Expand All @@ -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
}
Expand Down
2 changes: 1 addition & 1 deletion .vortex/tests/bats/docker-compose.bats
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 2 additions & 2 deletions README.dist.md
Original file line number Diff line number Diff line change
Expand Up @@ -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:<br/>
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.

Expand All @@ -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.

Expand Down

0 comments on commit f383789

Please sign in to comment.