-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(docker-dev): set up elasticsearch using local mapping on doc…
…ker-compose.dev (#2137) Co-authored-by: Dexter Lee <[email protected]>
- Loading branch information
1 parent
d2745ee
commit e7c3fd8
Showing
3 changed files
with
27 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,21 @@ | ||
# This "container" is a workaround to pre-create search indices | ||
FROM jwilder/dockerize:0.6.1 | ||
|
||
# Defining environment | ||
ARG APP_ENV=prod | ||
|
||
FROM jwilder/dockerize:0.6.1 AS base | ||
|
||
RUN apk add --no-cache curl jq | ||
|
||
FROM base AS prod-install | ||
|
||
COPY docker/elasticsearch-setup/create-indices.sh / | ||
RUN chmod 755 create-indices.sh | ||
COPY gms/impl/src/main/resources/index / | ||
COPY gms/impl/src/main/resources/index /index | ||
|
||
FROM base AS dev-install | ||
# Dummy stage for development. Use local files for setup | ||
# See this excellent thread https://github.com/docker/cli/issues/1134 | ||
|
||
FROM ${APP_ENV}-install AS final | ||
CMD dockerize -wait http://$ELASTICSEARCH_HOST:$ELASTICSEARCH_PORT -timeout 120s /create-indices.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters