Skip to content

Commit

Permalink
#7 - geopython/pygeoapi#325 trying to get ES running - now ok, remain…
Browse files Browse the repository at this point in the history
…s pygeoapi container
  • Loading branch information
justb4 committed Jan 13, 2020
1 parent 6ed0ddd commit db722d5
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
14 changes: 8 additions & 6 deletions services/pygeoapi_cite/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,18 @@ services:

elasticsearch_cite:
image: geopython/elasticsearch_cite:latest

# image: docker.elastic.co/elasticsearch/elasticsearch:7.5.1
build: ./elasticsearch

container_name: elasticsearch_cite

environment:
- node.name=elasticsearch_cite
- cluster.name=es-docker-cluster
# - discovery.seed_hosts=es02,es03
- cluster.initial_master_nodes=elasticsearch_cite
- discovery.type=single-node
- xpack.security.enabled=false
- ES_JAVA_OPTS=-Xms1G -Xmx1G -Des.enforce.bootstrap.checks=true
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"

ulimits:
nofile:
Expand All @@ -35,10 +37,10 @@ services:
container_name: pygeoapi_cite

depends_on:
- elasticsearch
- elasticsearch_cite

links:
- elasticsearch
- elasticsearch_cite

restart: unless-stopped

Expand Down
3 changes: 3 additions & 0 deletions services/pygeoapi_cite/elasticsearch/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ COPY add_data.sh /add_data.sh
RUN chmod +x /*.sh

USER elasticsearch
# CMD ["elasticsearch"]

# EXPOSE 9200 9300

# CMD ["/usr/share/elasticsearch/bin/elasticsearch"]

Expand Down
5 changes: 2 additions & 3 deletions services/pygeoapi_cite/elasticsearch/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@

# wait for Elasticsearch to start, then run the setup script to
# create and configure the index.
# exec /usr/share/elasticsearch/bin/wait-for-it.sh localhost:9200 -- /add_data.sh &
# exec $@
exec /usr/share/elasticsearch/bin/elasticsearch

exec /usr/share/elasticsearch/bin/wait-for-it.sh localhost:9200 -- /add_data.sh &
exec /usr/local/bin/docker-entrypoint.sh
# /wait-for-elasticsearch.sh http://elasticsearch:9200 /entrypoint.sh || echo "Elasticsearch failed: $?, exit" && exit 1

0 comments on commit db722d5

Please sign in to comment.