Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: dotenv support - allow to change the used OpenSearch version (ddev 1.23.5) #7

Merged
merged 7 commits into from
Oct 19, 2024

Conversation

cmuench
Copy link
Collaborator

@cmuench cmuench commented Oct 19, 2024

Add the following variables:

  • OPENSEARCH_TAG -> defines the tag of the used opensearch image
  • INSTALL_PLUGIN_ANALYSIS_PHONETIC: boolean var
  • INSTALL_PLUGIN_ANALYSIS_ICU: boolean var

docker-compose is now passing the args to the used Dockerfile

The Issue

Solve #6

How This PR Solves The Issue

  • Add args to Dockerfile
  • Define used build-args in docker-compose.yml

Manual Testing Instructions

Use new ddev 1.23.5 and define a dotenv file.

ddev dotenv set .ddev/.env.opensearch --opensearch-tag=2.15.0 --opensearch-dashboards-tag=2.15.0 --install-plugin-analytics-phoenetic=false --install-plugin-analytics-icu=false
ddev add-on get https://github.com/cmuench/ddev-opensearch/tarball/feature/dotenv-support

Related Issue Link(s)

Release/Deployment Notes

It should not have affects.

Christian Münch added 2 commits October 19, 2024 15:37
Add the following variables:

- OPENSEARCH_TAG -> defines the tag of the used opensearch image
- INSTALL_PLUGIN_ANALYSIS_PHONETIC: boolean var
- INSTALL_PLUGIN_ANALYSIS_ICU: boolean var

docker-compose is now passing the args to the used Dockerfile
@cmuench cmuench requested a review from stasadev October 19, 2024 14:02
@cmuench cmuench changed the title Feature/dotenv support feature: dotenv support - allow to change the used OpenSearch version (ddev 1.23.5) Oct 19, 2024
Copy link
Member

@stasadev stasadev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great, thank you!

Let's replace ddev get with ddev add-on get in the bats tests and add release tag to bats, see:

README.md Outdated Show resolved Hide resolved
@cmuench cmuench requested a review from stasadev October 19, 2024 14:19
@stasadev
Copy link
Member

stasadev commented Oct 19, 2024

Thank you, and the release test can also be updated to:

# bats test_tags=release
@test "install from release" {
  set -eu -o pipefail
  cd ${TESTDIR} || ( printf "unable to cd to ${TESTDIR}\n" && exit 1 )
  echo "# ddev add-on get ${ADDON_PATH} with project ${PROJNAME} in ${TESTDIR} ($(pwd))" >&3
  ddev add-on get ${ADDON_PATH}
  health_checks
}

bats test_tags=release ensures that it will not try to install the released version of this add-on from PR.

@cmuench
Copy link
Collaborator Author

cmuench commented Oct 19, 2024

Thank you, and the release test can also be updated to:

# bats test_tags=release
@test "install from release" {
  set -eu -o pipefail
  cd ${TESTDIR} || ( printf "unable to cd to ${TESTDIR}\n" && exit 1 )
  echo "# ddev add-on get ${ADDON_PATH} with project ${PROJNAME} in ${TESTDIR} ($(pwd))" >&3
  ddev add-on get ${ADDON_PATH}
  health_checks
}

bats test_tags=release ensures that it will not try to install the released version add-on from PR

Sorry. Forgot it... One second.

README.md Show resolved Hide resolved
Co-authored-by: Stanislav Zhuk <[email protected]>
Copy link
Member

@stasadev stasadev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thank you!

@cmuench
Copy link
Collaborator Author

cmuench commented Oct 19, 2024

Great, thank you!

Thanks for reviewing it.

@cmuench cmuench merged commit 8925265 into ddev:main Oct 19, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants