diff --git a/.dockerignore b/.dockerignore index f5dd9353bfba502c313d9b1076d2f36e129f00af..e2aa882e7c2b5218347df04f3e3e3342f54d28b0 100644 --- a/.dockerignore +++ b/.dockerignore @@ -4,8 +4,7 @@ .vscode/ .volumes/ data/ -docs/ infrastructure/ gui/ __pycache__/ -*.pyc \ No newline at end of file +*.pyc diff --git a/Dockerfile b/Dockerfile index 472f425283553f968fdff0f12c30116bc814b404..1208c0fb68076d82548570065757ad239e3abb63 100644 --- a/Dockerfile +++ b/Dockerfile @@ -39,11 +39,13 @@ RUN python nomad/dependencies.py FROM final # transfer installed packages from dependency stage COPY --from=dependencies /usr/local/lib/python3.6/site-packages /usr/local/lib/python3.6/site-packages +COPY --from=dependencies /usr/local/bin/sphinx-build /usr/local/bin/sphinx-build # we also need to copy the install dir, since nomad coe deps are installed with -e # TODO that should be changed in production! COPY --from=dependencies /install /install # do stuff +RUN apt-get update && apt-get install -y make COPY . /app WORKDIR /app RUN pip install -e . diff --git a/infrastructure/nomadxt/.docker-compose.yml.swp b/infrastructure/nomadxt/.docker-compose.yml.swp new file mode 100644 index 0000000000000000000000000000000000000000..bc9197fcb13d71757a37f0cf6044211268f30c82 Binary files /dev/null and b/infrastructure/nomadxt/.docker-compose.yml.swp differ diff --git a/infrastructure/nomad-xt/.env b/infrastructure/nomadxt/.env_local similarity index 88% rename from infrastructure/nomad-xt/.env rename to infrastructure/nomadxt/.env_local index 66259b8f341e489c791c7f647d446a8e5b5afc3e..abf59bf08bc580fb13eacbdaa117c82a600c8ddf 100644 --- a/infrastructure/nomad-xt/.env +++ b/infrastructure/nomadxt/.env_local @@ -6,4 +6,4 @@ MONGO_HOST_PORT=27017 KIBANA_HOST_PORT=5601 API_HOST_PORT=8000 -GUI_HOST_PORT=8005 \ No newline at end of file +GUI_HOST_PORT=8005 diff --git a/infrastructure/nomad-xt/enc-processing.env b/infrastructure/nomadxt/.env_processing similarity index 63% rename from infrastructure/nomad-xt/enc-processing.env rename to infrastructure/nomadxt/.env_processing index 26017ca8daf46f77ce74dec24003be0de6a4c246..a1de47e6445b8f607ed27d48ea3bb4ad01220320 100644 --- a/infrastructure/nomad-xt/enc-processing.env +++ b/infrastructure/nomadxt/.env_processing @@ -5,5 +5,7 @@ ELASTIC_HOST_PORT=10200 MONGO_HOST_PORT=10017 KIBANA_HOST_PORT=10601 -API_HOST_PORT=8000 -GUI_HOST_PORT=8005 \ No newline at end of file +API_HOST_PORT=8083 +GUI_HOST_PORT=127.0.0.1:8003 + +ELASTIC_VOLUME=nomadxt_elastic diff --git a/infrastructure/nomadxt/.gitignore b/infrastructure/nomadxt/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..4c49bd78f1d08f2bc09fa0bd8191ed38b7dce5e3 --- /dev/null +++ b/infrastructure/nomadxt/.gitignore @@ -0,0 +1 @@ +.env diff --git a/infrastructure/nomad-xt/docker-compose.yml b/infrastructure/nomadxt/docker-compose.yml similarity index 91% rename from infrastructure/nomad-xt/docker-compose.yml rename to infrastructure/nomadxt/docker-compose.yml index b13b1633408a6a7fe78fa2333e1701102e5e8de0..057b6a47fd7e6b5e2d0b453b63afd7b6162745d5 100644 --- a/infrastructure/nomad-xt/docker-compose.yml +++ b/infrastructure/nomadxt/docker-compose.yml @@ -20,7 +20,7 @@ services: restart: always image: minio/minio:RELEASE.2018-06-08T03-49-38Z # image: minio/minio - container_name: nomad-xt-minio + container_name: nomadxt_minio ports: - ${MINIO_HOST_PORT}:9000 volumes: @@ -35,7 +35,7 @@ services: rabbitmq: restart: always image: rabbitmq - container_name: nomad-xt-rabbitmq + container_name: nomadxt_rabbitmq environment: - RABBITMQ_ERLANG_COOKIE=SWQOKODSQALRPCLNMEQG - RABBITMQ_DEFAULT_USER=rabbitmq @@ -47,7 +47,7 @@ services: # results backend for celery redis: image: redis:3.0-alpine - container_name: nomad-xt-redis + container_name: nomadxt_redis command: redis-server --appendonly yes volumes: - ../../.volumes/redis:/data @@ -57,16 +57,15 @@ services: # the search engine elastic: image: docker.elastic.co/elasticsearch/elasticsearch:6.3.2 - container_name: nomad-xt-elastic volumes: - - ../../.volumes/elastic:/usr/share/elasticsearch/data + - nomadxt_elastic:/usr/share/elasticsearch/data ports: - ${ELASTIC_HOST_PORT}:9200 # the user data db mongo: image: mongo:latest - container_name: nomad-xt-mongo + container_name: nomadxt_mongo environment: - MONGO_DATA_DIR=/data/db - MONGO_LOG_DIR=/dev/null @@ -80,7 +79,7 @@ services: elk: restart: always build: ../elk/ - container_name: nomad-xt-elk + container_name: nomadxt_elk expose: - 5000 # logstash beats - 5044 # logstash tcp @@ -90,7 +89,6 @@ services: # nomad processing worker worker: build: ../../ - container_name: nomad-xt-worker environment: - NOMAD_MINIO_PORT=9000 - NOMAD_MINIO_HOST=minio @@ -158,4 +156,7 @@ services: links: - api ports: - - ${GUI_HOST_PORT}:80 \ No newline at end of file + - ${GUI_HOST_PORT}:80 + +volumes: + nomadxt_elastic: diff --git a/requirements.Dockerfile b/requirements.Dockerfile index dad1e652a75ca14f12a1cf0d85318251fd68b8b7..92e95fd4b019e94f4d6a0b907fbae8682692143d 100644 --- a/requirements.Dockerfile +++ b/requirements.Dockerfile @@ -24,4 +24,4 @@ WORKDIR /install COPY requirements.txt requirements.txt COPY requirements-dep.txt requirements-dep.txt RUN pip install -r requirements.txt -RUN pip install -r requirements-dep.txt \ No newline at end of file +RUN pip install -r requirements-dep.txt