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

refactor(docker-dev): set up elasticsearch using local mapping on docker-compose.dev #2137

Merged
merged 3 commits into from
Feb 25, 2021

Conversation

dexter-mh-lee
Copy link
Contributor

@dexter-mh-lee dexter-mh-lee commented Feb 24, 2021

Make it easy to test mapping/setting.json changes by adding an elasticsearch-setup:debug image to docker-compose.dev.yml

The overridden elasticsearch-setup container mounts the local mapping/setting.json files and uses them to create indices.
Followed the method used in the dev setup for gms/mae-consumer/mce-consumer containers

Test
./docker/dev.sh runs correctly and confirmed that the local changes to mappings got picked up
Running the prod path by doing the following (Thanks @jplaisted)

cd docker
./nuke.sh # start from scratch to really verify things
docker compose pull # pull latest images
docker image rm docker_elasticsearch-setup # delete pulled image
docker-compose build elasticsearch-setup # rebuild image
docker-compose -p datahub up # launch docker without pulling

ran correctly as well.

Checklist

  • The PR conforms to DataHub's Contributing Guideline (particularly Commit Message Format)
  • Links to related issues (if applicable)
  • Tests for the changes have been added/updated (if applicable)
  • Docs related to the changes have been added/updated (if applicable)

Copy link
Contributor

@jplaisted jplaisted left a comment

Choose a reason for hiding this comment

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

Good catch that we didn't have a developer flow for for this. Agree with the change, so long as we can verify both the "dev" and "prod" docker images work as expected.

--

Edit: github erased my review comment, give me a second to retype it. Some bad UX here :|

@jplaisted jplaisted merged commit e7c3fd8 into datahub-project:master Feb 25, 2021
@jplaisted
Copy link
Contributor

Thanks!

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