Skip to content
Snippets Groups Projects
Verified Commit c10d8f18 authored by Martin Weise's avatar Martin Weise
Browse files

Initial config

parent 85b33aab
No related branches found
No related tags found
No related merge requests found
Showing
with 699 additions and 271 deletions
API="http://fda-gateway-service:9095" METADATA_DB=fda
MAIL_HOST="stmp.example.com" METADATA_USERNAME=postgres
MAIL_PORT="587" METADATA_PASSWORD=postgres
MAIL_USERNAME="user" BROKER_USERNAME=fda
MAIL_PASSWORD="pass" BROKER_PASSWORD=fda
WEBSITE=http://example.com
MAIL_FROM=Database Repository <noreply@example.com>
MAIL_REPLY_TO=Admin <somebody@example.com>
JWT_ISSUER=dbrepo
JWT_SECRET=secret
JWT_EXPIRATION=86400000
SMTP_HOST=
SMTP_PORT=
SMTP_USERNAME=
SMTP_PASSWORD=
EUREKA_SERVER=http://discovery-service:9090/eureka/
SHARED_FILESYSTEM=/tmp
\ No newline at end of file
#!/bin/bash #!/bin/bash
echo "=== [ Stopping dbrepo-* ] ==="
docker container stop $(docker container ls -aq -f name=^/dbrepo-.*) || true
echo "=== [ Removing dbrepo-* ] ==="
docker container rm $(docker container ls -aq -f name=^/dbrepo-.*) || true
docker volume rm $(docker volume ls -q -f name=^dbrepo-.*) || true
docker network rm $(docker network ls -q -f name=^/dbrepo-.*) || true
echo "=== [ Stopping fda-* ] ==="
docker container stop $(docker container ls -aq -f name=^/fda-.*) || true docker container stop $(docker container ls -aq -f name=^/fda-.*) || true
echo "=== [ Removing fda-* ] ==="
docker container rm $(docker container ls -aq -f name=^/fda-.*) || true docker container rm $(docker container ls -aq -f name=^/fda-.*) || true
docker volume rm $(docker volume ls -q -f name=^fda-.*) || true docker volume rm $(docker volume ls -q -f name=^fda-.*) || true
docker network rm $(docker network ls -q -f name=^/fda-.*) || true docker network rm $(docker network ls -q -f name=^/fda-.*) || true
\ No newline at end of file
TAG ?= latest
all: all:
clean:
config-backend: config-backend:
./.fda-deployment/fda-authentication-service/install_smtp ./.fda-deployment/fda-authentication-service/install_smtp
...@@ -53,69 +57,87 @@ build-frontend: ...@@ -53,69 +57,87 @@ build-frontend:
yarn --cwd ./fda-ui install --legacy-peer-deps yarn --cwd ./fda-ui install --legacy-peer-deps
yarn --cwd ./fda-ui run build yarn --cwd ./fda-ui run build
tag: tag-identifier tag-container tag-database tag-discovery tag-gateway tag-query tag-table tag-document tag-units tag-broker tag: tag-identifier tag-container tag-database tag-discovery tag-gateway tag-query tag-table tag-analyse tag-authentication tag-metadata-db tag-ui tag-units tag-broker
tag-analyse:
docker tag "fda-analyse-service:${TAG}" "dbrepo/analyse-service:${TAG}"
tag-authentication:
docker tag "fda-authentication-service:${TAG}" "dbrepo/authentication-service:${TAG}"
tag-metadata-db:
docker tag "fda-metadata-db:${TAG}" "dbrepo/metadata-db:${TAG}"
tag-ui:
docker tag "fda-ui:${TAG}" "dbrepo/ui:${TAG}"
tag-identifier: tag-identifier:
docker tag fda-identifier-service:latest fairdataaustria/fda-identifier-service:latest docker tag "fda-identifier-service:${TAG}" "dbrepo/identifier-service:${TAG}"
tag-container: tag-container:
docker tag fda-container-service:latest fairdataaustria/fda-container-service:latest docker tag "fda-container-service:${TAG}" "dbrepo/container-service:${TAG}"
tag-database: tag-database:
docker tag fda-database-service:latest fairdataaustria/fda-database-service:latest docker tag "fda-database-service:${TAG}" "dbrepo/database-service:${TAG}"
tag-discovery: tag-discovery:
docker tag fda-discovery-service:latest fairdataaustria/fda-discovery-service:latest docker tag "fda-discovery-service:${TAG}" "dbrepo/discovery-service:${TAG}"
tag-gateway: tag-gateway:
docker tag fda-gateway-service:latest fairdataaustria/fda-gateway-service:latest docker tag "fda-gateway-service:${TAG}" "dbrepo/gateway-service:${TAG}"
tag-query: tag-query:
docker tag fda-query-service:latest fairdataaustria/fda-query-service:latest docker tag "fda-query-service:${TAG}" "dbrepo/query-service:${TAG}"
tag-table: tag-table:
docker tag fda-table-service:latest fairdataaustria/fda-table-service:latest docker tag "fda-table-service:${TAG}" "dbrepo/table-service:${TAG}"
tag-document:
docker tag fda-document-service:latest fairdataaustria/fda-document-service:latest
tag-units: tag-units:
docker tag fda-units-service:latest fairdataaustria/fda-units-service:latest docker tag "fda-units-service:${TAG}" "dbrepo/units-service:${TAG}"
tag-broker: tag-broker:
docker tag fda-units-service:latest fairdataaustria/fda-broker-service:latest docker tag "fda-broker-service:${TAG}" "dbrepo/broker-service:${TAG}"
release: build-docker tag release-identifier release-container release-database release-discovery release-gateway release-query release-table release-analyse release-authentication release-metadata-db release-ui release-units release-broker
release-analyse:
docker push "dbrepo/analyse-service:${TAG}"
release: tag release-identifier release-container release-database release-discovery release-gateway release-query release-table release-document release-units release-broker release-authentication:
docker push "dbrepo/authentication-service:${TAG}"
release-metadata-db:
docker push "dbrepo/metadata-db:${TAG}"
release-ui:
docker push "dbrepo/ui:${TAG}"
release-identifier: release-identifier:
docker push fairdataaustria/fda-identifier-service:latest docker push "dbrepo/identifier-service:${TAG}"
release-container: release-container:
docker push fairdataaustria/fda-container-service:latest docker push "dbrepo/container-service:${TAG}"
release-database: release-database:
docker push fairdataaustria/fda-database-service:latest docker push "dbrepo/database-service:${TAG}"
release-discovery: release-discovery:
docker push fairdataaustria/fda-discovery-service:latest docker push "dbrepo/discovery-service:${TAG}"
release-gateway: release-gateway:
docker push fairdataaustria/fda-gateway-service:latest docker push "dbrepo/gateway-service:${TAG}"
release-query: release-query:
docker push fairdataaustria/fda-query-service:latest docker push "dbrepo/query-service:${TAG}"
release-table: release-table:
docker push fairdataaustria/fda-table-service:latest docker push "dbrepo/table-service:${TAG}"
release-document:
docker push fairdataaustria/fda-document-service:latest
release-units: release-units:
docker push fairdataaustria/fda-units-service:latest docker push "dbrepo/units-service:${TAG}"
release-broker: release-broker:
docker push fairdataaustria/fda-broker-service:latest docker push "dbrepo/broker-service:${TAG}"
test-backend: test-backend-auth test-backend-container test-backend-database test-backend-discovery test-backend-gateway test-backend-query test-backend-table test-backend: test-backend-auth test-backend-container test-backend-database test-backend-discovery test-backend-gateway test-backend-query test-backend-table
......
version: "3.6"
volumes:
metadata-db-data:
search-service-data:
broker-service-data:
networks:
public:
name: public
driver: bridge
ipam:
config:
- subnet: 172.29.0.0/16
userdb:
name: userdb
driver: bridge
ipam:
config:
- subnet: 172.28.0.0/16
services:
metadata-db:
restart: on-failure
container_name: dbrepo-metadata-db
hostname: metadata-db
image: dbrepo/metadata-db
networks:
public:
volumes:
- metadata-db-data:/var/lib/postgresql/data
ports:
- "5432:5432"
environment:
POSTGRES_DB: ${METADATA_DB}
POSTGRES_USER: ${METADATA_USERNAME}
POSTGRES_PASSWORD: ${METADATA_PASSWORD}
logging:
driver: json-file
discovery-service:
restart: on-failure
container_name: dbrepo-discovery-service
hostname: discovery-service
image: dbrepo/discovery-service
networks:
public:
ports:
- "9090:9090"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
logging:
driver: json-file
gateway-service:
restart: on-failure
container_name: dbrepo-gateway-service
hostname: gateway-service
image: dbrepo/gateway-service
networks:
public:
ports:
- "9095:9095"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
depends_on:
discovery-service:
condition: service_healthy
logging:
driver: json-file
database-service:
restart: on-failure
container_name: dbrepo-database-service
hostname: database-service
image: dbrepo/database-service
networks:
userdb:
public:
ports:
- "9092:9092"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
container-service:
condition: service_healthy
broker-service:
condition: service_healthy
authentication-service:
condition: service_healthy
logging:
driver: json-file
container-service:
restart: on-failure
container_name: dbrepo-container-service
hostname: container-service
image: dbrepo/container-service
networks:
public:
ports:
- "9091:9091"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
authentication-service:
condition: service_healthy
logging:
driver: json-file
authentication-service:
restart: on-failure
container_name: dbrepo-authentication-service
hostname: authentication-service
image: dbrepo/authentication-service
networks:
public:
ports:
- "9097:9097"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
WEBSITE: ${WEBSITE}
MAIL_FROM: ${MAIL_FROM}
MAIL_REPLY_TO: ${MAIL_REPLY_TO}
JWT_ISSUER: ${JWT_ISSUER}
JWT_SECRET: ${JWT_SECRET}
JWT_EXPIRATION: ${JWT_EXPIRATION}
SMTP_HOST: ${SMTP_HOST}
SMTP_PORT: ${SMTP_PORT}
SMTP_USERNAME: ${SMTP_USERNAME}
SMTP_PASSWORD: ${SMTP_PASSWORD}
depends_on:
discovery-service:
condition: service_healthy
broker-service:
condition: service_healthy
metadata-db:
condition: service_healthy
logging:
driver: json-file
query-service:
restart: on-failure
container_name: dbrepo-query-service
hostname: query-service
image: dbrepo/query-service
networks:
public:
userdb:
ports:
- "9093:9093"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes:
- /tmp:/tmp
depends_on:
table-service:
condition: service_healthy
authentication-service:
condition: service_healthy
logging:
driver: json-file
table-service:
restart: on-failure
container_name: dbrepo-table-service
hostname: table-service
image: dbrepo/table-service
networks:
public:
userdb:
ports:
- "9094:9094"
environment:
multipart.location: ${SHARED_FILESYSTEM}
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ${SHARED_FILESYSTEM}:/tmp
depends_on:
authentication-service:
condition: service_healthy
search-service:
condition: service_started
broker-service:
condition: service_healthy
logging:
driver: json-file
identifier-service:
restart: on-failure
container_name: dbrepo-identifier-service
hostname: identifier-service
image: dbrepo/identifier-service
networks:
public:
ports:
- "9096:9096"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
depends_on:
query-service:
condition: service_healthy
authentication-service:
condition: service_healthy
logging:
driver: json-file
analyse-service:
restart: on-failure
container_name: dbrepo-analyse-service
hostname: analyse-service
image: dbrepo/analyse-service
networks:
public:
userdb:
command: sh -c "/wait && flask run" # docker-compose should not test the implementation
ports:
- "5000:5000"
volumes:
- ${SHARED_FILESYSTEM}:/tmp
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
discovery-service:
condition: service_healthy
logging:
driver: json-file
units-service:
restart: on-failure
container_name: dbrepo-units-service
hostname: units-service
image: dbrepo/units-service
networks:
public:
ports:
- "5010:5010"
volumes:
- /tmp:/tmp
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
discovery-service:
condition: service_healthy
logging:
driver: json-file
broker-service:
restart: on-failure
container_name: dbrepo-broker-service
hostname: broker-service
image: dbrepo/broker-service
networks:
public:
ports:
- "5672:5672"
- "9098:9098"
- "15672:15672"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
RABBITMQ_DEFAULT_USER: ${BROKER_USERNAME}
RABBITMQ_DEFAULT_PASS: ${BROKER_PASSWORD}
depends_on:
discovery-service:
condition: service_healthy
volumes:
- broker-service-data:/var/lib/rabbitmq/
logging:
driver: json-file
search-service:
restart: always
container_name: dbrepo-search-service
hostname: search-service
image: elasticsearch:7.13.4
command: [ "elasticsearch" ]
networks:
public:
environment:
- discovery.type=single-node
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- logger.level=WARN
depends_on:
discovery-service:
condition: service_healthy
ports:
- 9200:9200
- 9600:9600
volumes:
- search-service-data:/usr/share/elasticsearch/data
logging:
driver: json-file
ui:
restart: on-failure
container_name: dbrepo-ui
hostname: ui
image: dbrepo/ui
networks:
public:
ports:
- "443:3000"
volumes:
- ${SHARED_FILESYSTEM}:/tmp
depends_on:
identifier-service:
condition: service_healthy
database-service:
condition: service_healthy
environment:
KEY: "${UI_KEY}"
CERT: "${UI_CERT}"
logging:
driver: json-file
version: "3.6" version: "3.6"
volumes: volumes:
fda-metadata-db-data: metadata-db-data:
fda-search-service-data: search-service-data:
fda-broker-service-data: broker-service-data:
networks: networks:
fda-public: public:
name: fda-public name: public
driver: bridge driver: bridge
ipam: ipam:
config: config:
- subnet: 172.29.0.0/16 - subnet: 172.29.0.0/16
fda-userdb: userdb:
name: fda-userdb name: userdb
driver: bridge driver: bridge
ipam: ipam:
config: config:
...@@ -21,325 +21,323 @@ networks: ...@@ -21,325 +21,323 @@ networks:
services: services:
fda-metadata-db: metadata-db:
restart: on-failure restart: on-failure
container_name: fda-metadata-db container_name: dbrepo-metadata-db
hostname: fda-metadata-db hostname: metadata-db
build: ./fda-metadata-db image: dbrepo/metadata-db
image: fda-metadata-db
networks: networks:
fda-public: public:
volumes: volumes:
- fda-metadata-db-data:/var/lib/postgresql/data - metadata-db-data:/var/lib/postgresql/data
ports: ports:
- "5432:5432" - "5432:5432"
environment: environment:
POSTGRES_USER: postgres POSTGRES_DB: ${METADATA_DB}
POSTGRES_PASSWORD: postgres POSTGRES_USER: ${METADATA_USERNAME}
POSTGRES_DB: fda POSTGRES_PASSWORD: ${METADATA_PASSWORD}
logging: logging:
driver: json-file driver: json-file
fda-discovery-service: discovery-service:
restart: on-failure restart: on-failure
container_name: fda-discovery-service container_name: dbrepo-discovery-service
hostname: fda-discovery-service hostname: discovery-service
build: ./fda-discovery-service image: dbrepo/discovery-service
image: fda-discovery-service
networks: networks:
fda-public: public:
environment:
SPRING_PROFILES_ACTIVE: docker
ports: ports:
- "9090:9090" - "9090:9090"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
logging: logging:
driver: json-file driver: json-file
fda-gateway-service: gateway-service:
restart: on-failure restart: on-failure
container_name: fda-gateway-service container_name: dbrepo-gateway-service
hostname: fda-gateway-service hostname: gateway-service
build: ./fda-gateway-service image: dbrepo/gateway-service
image: fda-gateway-service
networks: networks:
fda-public: public:
environment:
SPRING_PROFILES_ACTIVE: docker
ports: ports:
- "9095:9095" - "9095:9095"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
depends_on: depends_on:
fda-discovery-service: discovery-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-database-service: database-service:
restart: on-failure restart: on-failure
container_name: fda-database-service container_name: dbrepo-database-service
hostname: fda-database-service hostname: database-service
build: ./fda-database-service image: dbrepo/database-service
image: fda-database-service
networks: networks:
fda-userdb: userdb:
fda-public: public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SEARCH_ENDPOINT: fda-search-service:9200
SPRING_PROFILES_ACTIVE: docker
ports: ports:
- "9092:9092" - "9092:9092"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes: volumes:
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
depends_on: depends_on:
fda-container-service: container-service:
condition: service_healthy condition: service_healthy
fda-broker-service: broker-service:
condition: service_healthy condition: service_healthy
fda-authentication-service: authentication-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-container-service: container-service:
restart: on-failure restart: on-failure
container_name: fda-container-service container_name: dbrepo-container-service
hostname: fda-container-service hostname: container-service
build: ./fda-container-service image: dbrepo/container-service
image: fda-container-service
networks: networks:
fda-public: public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SPRING_PROFILES_ACTIVE: docker
ports: ports:
- "9091:9091" - "9091:9091"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes: volumes:
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
depends_on: depends_on:
fda-authentication-service: authentication-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-authentication-service: authentication-service:
restart: on-failure restart: on-failure
container_name: fda-authentication-service container_name: dbrepo-authentication-service
hostname: fda-authentication-service hostname: authentication-service
image: fda-authentication-service image: dbrepo/authentication-service
build: fda-authentication-service
networks: networks:
fda-public: public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
WEBSITE: http://localhost:3000
MAIL_FROM: Database Repository <noreply@dbrepo.ossdip.at>
MAIL_REPLY_TO: Martin Weise <martin.weise@tuwien.ac.at>
JWT_ISSUER: fda-dbrepo
JWT_SECRET: fda-secret
JWT_EXPIRATION: 86400000
SPRING_PROFILES_ACTIVE: docker
SMTP_HOST: ${MAIL_HOST}
SMTP_PORT: ${MAIL_PORT}
SMTP_USERNAME: ${MAIL_USERNAME}
SMTP_PASSWORD: ${MAIL_PASSWORD}
ports: ports:
- "9097:9097" - "9097:9097"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
WEBSITE: ${WEBSITE}
MAIL_FROM: ${MAIL_FROM}
MAIL_REPLY_TO: ${MAIL_REPLY_TO}
JWT_ISSUER: ${JWT_ISSUER}
JWT_SECRET: ${JWT_SECRET}
JWT_EXPIRATION: ${JWT_EXPIRATION}
SMTP_HOST: ${SMTP_HOST}
SMTP_PORT: ${SMTP_PORT}
SMTP_USERNAME: ${SMTP_USERNAME}
SMTP_PASSWORD: ${SMTP_PASSWORD}
depends_on: depends_on:
fda-discovery-service: discovery-service:
condition: service_healthy condition: service_healthy
fda-broker-service: broker-service:
condition: service_healthy condition: service_healthy
fda-metadata-db: metadata-db:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-query-service: query-service:
restart: on-failure restart: on-failure
container_name: fda-query-service container_name: dbrepo-query-service
hostname: fda-query-service hostname: query-service
build: ./fda-query-service image: dbrepo/query-service
image: fda-query-service
networks: networks:
fda-public: public:
fda-userdb: userdb:
environment:
SPRING_PROFILES_ACTIVE: docker
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
ports: ports:
- "9093:9093" - "9093:9093"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes: volumes:
- /tmp:/tmp - /tmp:/tmp
depends_on: depends_on:
fda-table-service: table-service:
condition: service_healthy condition: service_healthy
fda-authentication-service: authentication-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-table-service: table-service:
restart: on-failure restart: on-failure
container_name: fda-table-service container_name: dbrepo-table-service
hostname: fda-table-service hostname: table-service
build: ./fda-table-service image: dbrepo/table-service
image: fda-table-service
networks: networks:
fda-public: public:
fda-userdb: userdb:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SEARCH_ENDPOINT: fda-search-service:9200
SPRING_PROFILES_ACTIVE: docker
multipart.location: /tmp
ports: ports:
- "9094:9094" - "9094:9094"
environment:
multipart.location: ${SHARED_FILESYSTEM}
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
volumes: volumes:
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
- /tmp:/tmp - ${SHARED_FILESYSTEM}:/tmp
depends_on: depends_on:
fda-authentication-service: authentication-service:
condition: service_healthy condition: service_healthy
fda-search-service: search-service:
condition: service_started condition: service_started
fda-broker-service: broker-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-identifier-service: identifier-service:
restart: on-failure restart: on-failure
container_name: fda-identifier-service container_name: dbrepo-identifier-service
hostname: fda-identifier-service hostname: identifier-service
build: ./fda-identifier-service image: dbrepo/identifier-service
image: fda-identifier-service
networks: networks:
fda-public: public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SPRING_PROFILES_ACTIVE: docker
ports: ports:
- "9096:9096" - "9096:9096"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
depends_on: depends_on:
fda-query-service: query-service:
condition: service_healthy condition: service_healthy
fda-authentication-service: authentication-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-analyse-service: analyse-service:
restart: on-failure restart: on-failure
container_name: fda-analyse-service container_name: dbrepo-analyse-service
hostname: fda-analyse-service hostname: analyse-service
build: ./fda-analyse-service image: dbrepo/analyse-service
image: fda-analyse-service
networks: networks:
fda-public: public:
fda-userdb: userdb:
command: sh -c "/wait && flask run" # docker-compose should not test the implementation command: sh -c "/wait && flask run" # docker-compose should not test the implementation
environment:
EUREKA_SERVER: http://fda-discovery-service:9090/eureka/
ports: ports:
- "5000:5000" - "5000:5000"
volumes: volumes:
- /tmp:/tmp - ${SHARED_FILESYSTEM}:/tmp
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
depends_on: depends_on:
fda-discovery-service: discovery-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-units-service: units-service:
restart: on-failure restart: on-failure
container_name: fda-units-service container_name: dbrepo-units-service
hostname: fda-units-service hostname: units-service
build: ./fda-units-service image: dbrepo/units-service
image: fda-units-service
networks: networks:
fda-public: public:
environment:
EUREKA_SERVER: http://fda-discovery-service:9090/eureka/
ports: ports:
- "5010:5010" - "5010:5010"
volumes: volumes:
- /tmp:/tmp - /tmp:/tmp
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
depends_on: depends_on:
fda-discovery-service: discovery-service:
condition: service_healthy condition: service_healthy
logging: logging:
driver: json-file driver: json-file
fda-broker-service: broker-service:
restart: on-failure restart: on-failure
container_name: fda-broker-service container_name: dbrepo-broker-service
hostname: fda-broker-service hostname: broker-service
build: ./fda-broker-service image: dbrepo/broker-service
image: fda-broker-service
environment:
SPRING_PROFILES_ACTIVE: docker
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
networks: networks:
fda-public: public:
ports: ports:
- "5672:5672" - "5672:5672"
- "9098:9098" - "9098:9098"
- "15672:15672" - "15672:15672"
environment:
METADATA_DB: ${METADATA_DB}
METADATA_USERNAME: ${METADATA_USERNAME}
METADATA_PASSWORD: ${METADATA_PASSWORD}
BROKER_USERNAME: ${BROKER_USERNAME}
BROKER_PASSWORD: ${BROKER_PASSWORD}
RABBITMQ_DEFAULT_USER: ${BROKER_USERNAME}
RABBITMQ_DEFAULT_PASS: ${BROKER_PASSWORD}
depends_on: depends_on:
fda-discovery-service: discovery-service:
condition: service_healthy condition: service_healthy
volumes: volumes:
- fda-broker-service-data:/var/lib/rabbitmq/ - broker-service-data:/var/lib/rabbitmq/
logging: logging:
driver: json-file driver: json-file
fda-search-service: search-service:
restart: always restart: always
container_name: fda-search-service container_name: dbrepo-search-service
hostname: fda-search-service hostname: search-service
image: elasticsearch:7.13.4 image: elasticsearch:7.13.4
command: [ "elasticsearch" ] command: [ "elasticsearch" ]
networks: networks:
fda-public: public:
environment: environment:
- discovery.type=single-node - discovery.type=single-node
- "ES_JAVA_OPTS=-Xms512m -Xmx512m" - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- logger.level=WARN - logger.level=WARN
depends_on: depends_on:
fda-discovery-service: discovery-service:
condition: service_healthy condition: service_healthy
ports: ports:
- 9200:9200 - 9200:9200
- 9600:9600 - 9600:9600
volumes: volumes:
- fda-search-service-data:/usr/share/elasticsearch/data - search-service-data:/usr/share/elasticsearch/data
logging: logging:
driver: json-file driver: json-file
fda-ui: ui:
restart: on-failure restart: on-failure
container_name: fda-ui container_name: dbrepo-ui
hostname: fda-ui hostname: ui
build: ./fda-ui image: dbrepo/ui
image: fda-ui
networks: networks:
fda-public: public:
ports: ports:
- "443:3000" - "3000:3000"
volumes: volumes:
- /tmp:/tmp - ${SHARED_FILESYSTEM}:/tmp
- "./fda-ui/.prod:/certs"
depends_on: depends_on:
fda-identifier-service: identifier-service:
condition: service_healthy condition: service_healthy
fda-database-service: database-service:
condition: service_healthy condition: service_healthy
environment:
HOST: 0.0.0.0
API: http://fda-gateway-service:9095
KEY: "${UI_KEY}"
CERT: "${UI_CERT}"
logging: logging:
driver: json-file driver: json-file
...@@ -24,7 +24,7 @@ services: ...@@ -24,7 +24,7 @@ services:
fda-metadata-db: fda-metadata-db:
restart: on-failure restart: on-failure
container_name: fda-metadata-db container_name: fda-metadata-db
hostname: fda-metadata-db hostname: metadata-db
build: ./fda-metadata-db build: ./fda-metadata-db
image: fda-metadata-db image: fda-metadata-db
networks: networks:
...@@ -43,7 +43,7 @@ services: ...@@ -43,7 +43,7 @@ services:
fda-discovery-service: fda-discovery-service:
restart: on-failure restart: on-failure
container_name: fda-discovery-service container_name: fda-discovery-service
hostname: fda-discovery-service hostname: discovery-service
build: ./fda-discovery-service build: ./fda-discovery-service
image: fda-discovery-service image: fda-discovery-service
networks: networks:
...@@ -58,7 +58,7 @@ services: ...@@ -58,7 +58,7 @@ services:
fda-gateway-service: fda-gateway-service:
restart: on-failure restart: on-failure
container_name: fda-gateway-service container_name: fda-gateway-service
hostname: fda-gateway-service hostname: gateway-service
build: ./fda-gateway-service build: ./fda-gateway-service
image: fda-gateway-service image: fda-gateway-service
networks: networks:
...@@ -76,7 +76,7 @@ services: ...@@ -76,7 +76,7 @@ services:
fda-database-service: fda-database-service:
restart: on-failure restart: on-failure
container_name: fda-database-service container_name: fda-database-service
hostname: fda-database-service hostname: database-service
build: ./fda-database-service build: ./fda-database-service
image: fda-database-service image: fda-database-service
networks: networks:
...@@ -103,7 +103,7 @@ services: ...@@ -103,7 +103,7 @@ services:
fda-container-service: fda-container-service:
restart: on-failure restart: on-failure
container_name: fda-container-service container_name: fda-container-service
hostname: fda-container-service hostname: container-service
build: ./fda-container-service build: ./fda-container-service
image: fda-container-service image: fda-container-service
networks: networks:
...@@ -124,7 +124,7 @@ services: ...@@ -124,7 +124,7 @@ services:
fda-authentication-service: fda-authentication-service:
restart: on-failure restart: on-failure
container_name: fda-authentication-service container_name: fda-authentication-service
hostname: fda-authentication-service hostname: authentication-service
image: fda-authentication-service image: fda-authentication-service
build: fda-authentication-service build: fda-authentication-service
networks: networks:
...@@ -157,7 +157,7 @@ services: ...@@ -157,7 +157,7 @@ services:
fda-query-service: fda-query-service:
restart: on-failure restart: on-failure
container_name: fda-query-service container_name: fda-query-service
hostname: fda-query-service hostname: query-service
build: ./fda-query-service build: ./fda-query-service
image: fda-query-service image: fda-query-service
networks: networks:
...@@ -181,7 +181,7 @@ services: ...@@ -181,7 +181,7 @@ services:
fda-table-service: fda-table-service:
restart: on-failure restart: on-failure
container_name: fda-table-service container_name: fda-table-service
hostname: fda-table-service hostname: table-service
build: ./fda-table-service build: ./fda-table-service
image: fda-table-service image: fda-table-service
networks: networks:
...@@ -210,7 +210,7 @@ services: ...@@ -210,7 +210,7 @@ services:
fda-identifier-service: fda-identifier-service:
restart: on-failure restart: on-failure
container_name: fda-identifier-service container_name: fda-identifier-service
hostname: fda-identifier-service hostname: identifier-service
build: ./fda-identifier-service build: ./fda-identifier-service
image: fda-identifier-service image: fda-identifier-service
networks: networks:
...@@ -231,7 +231,7 @@ services: ...@@ -231,7 +231,7 @@ services:
fda-analyse-service: fda-analyse-service:
restart: on-failure restart: on-failure
container_name: fda-analyse-service container_name: fda-analyse-service
hostname: fda-analyse-service hostname: analyse-service
build: ./fda-analyse-service build: ./fda-analyse-service
image: fda-analyse-service image: fda-analyse-service
networks: networks:
...@@ -240,6 +240,7 @@ services: ...@@ -240,6 +240,7 @@ services:
command: sh -c "/wait && flask run" # docker-compose should not test the implementation command: sh -c "/wait && flask run" # docker-compose should not test the implementation
environment: environment:
EUREKA_SERVER: http://fda-discovery-service:9090/eureka/ EUREKA_SERVER: http://fda-discovery-service:9090/eureka/
hostname: analyse-service
ports: ports:
- "5000:5000" - "5000:5000"
volumes: volumes:
...@@ -254,7 +255,7 @@ services: ...@@ -254,7 +255,7 @@ services:
fda-units-service: fda-units-service:
restart: on-failure restart: on-failure
container_name: fda-units-service container_name: fda-units-service
hostname: fda-units-service hostname: units-service
build: ./fda-units-service build: ./fda-units-service
image: fda-units-service image: fda-units-service
networks: networks:
...@@ -275,7 +276,7 @@ services: ...@@ -275,7 +276,7 @@ services:
fda-broker-service: fda-broker-service:
restart: on-failure restart: on-failure
container_name: fda-broker-service container_name: fda-broker-service
hostname: fda-broker-service hostname: broker-service
build: ./fda-broker-service build: ./fda-broker-service
image: fda-broker-service image: fda-broker-service
environment: environment:
...@@ -298,7 +299,7 @@ services: ...@@ -298,7 +299,7 @@ services:
fda-search-service: fda-search-service:
restart: always restart: always
container_name: fda-search-service container_name: fda-search-service
hostname: fda-search-service hostname: search-service
image: elasticsearch:7.13.4 image: elasticsearch:7.13.4
command: [ "elasticsearch" ] command: [ "elasticsearch" ]
networks: networks:
...@@ -321,7 +322,7 @@ services: ...@@ -321,7 +322,7 @@ services:
fda-ui: fda-ui:
restart: on-failure restart: on-failure
container_name: fda-ui container_name: fda-ui
hostname: fda-ui hostname: ui
build: ./fda-ui build: ./fda-ui
image: fda-ui image: fda-ui
networks: networks:
......
...@@ -5,6 +5,8 @@ ENV FLASK_APP=app.py ...@@ -5,6 +5,8 @@ ENV FLASK_APP=app.py
ENV FLASK_RUN_HOST=0.0.0.0 ENV FLASK_RUN_HOST=0.0.0.0
ENV PORT_APP=5000 ENV PORT_APP=5000
ENV FLASK_ENV=production ENV FLASK_ENV=production
ENV HOSTNAME=analyse-service
ENV EUREKA_SERVER=http://discovery-service:9090/eureka/
WORKDIR /app WORKDIR /app
......
...@@ -143,9 +143,9 @@ def updatecol(): ...@@ -143,9 +143,9 @@ def updatecol():
rest_server_port = 5000 rest_server_port = 5000
eureka_client.init(eureka_server=os.getenv('EUREKA_SERVER', 'http://localhost:9090/eureka/'), eureka_client.init(eureka_server=os.getenv('EUREKA_SERVER', 'http://localhost:9090/eureka/'),
app_name="fda-analyse-service", app_name=os.getenv('HOSTNAME', 'analyse-service'),
instance_ip="fda-analyse-service", instance_ip=os.getenv('HOSTNAME', 'analyse-service'),
instance_host="fda-analyse-service", instance_host=os.getenv('HOSTNAME', 'analyse-service'),
instance_port=rest_server_port) instance_port=rest_server_port)
if __name__ == '__main__': if __name__ == '__main__':
......
...@@ -21,6 +21,21 @@ RUN mvn -q clean package -DskipTests ...@@ -21,6 +21,21 @@ RUN mvn -q clean package -DskipTests
###### THIRD STAGE ###### ###### THIRD STAGE ######
FROM openjdk:11-jre-slim as runtime FROM openjdk:11-jre-slim as runtime
ENV METADATA_DB=fda
ENV METADATA_USERNAME=postgres
ENV METADATA_PASSWORD=postgres
ENV WEBSITE=http://example.com
ENV GATEWAY_ENDPOINT=http://gateway-service:9095
ENV MAIL_FROM="Database Repository <noreply@example.com>"
ENV MAIL_REPLY_TO="Somebody <somebody@example.com>"
ENV JWT_ISSUER=dbrepo
ENV JWT_SECRET=secret
ENV JWT_EXPIRATION=86400000
ENV SMTP_HOST=""
ENV SMTP_PORT=""
ENV SMTP_USERNAME=""
ENV SMTP_PASSWORD=""
VOLUME /tmp VOLUME /tmp
COPY ./service_ready /usr/bin COPY ./service_ready /usr/bin
......
...@@ -2,7 +2,7 @@ app.version: '@project.version@' ...@@ -2,7 +2,7 @@ app.version: '@project.version@'
spring: spring:
main.banner-mode: off main.banner-mode: off
datasource: datasource:
url: jdbc:postgresql://localhost:5432/fda url: "jdbc:postgresql://metadata-db:5432/${METADATA_DB}"
driver-class-name: org.postgresql.Driver driver-class-name: org.postgresql.Driver
username: postgres username: postgres
password: postgres password: postgres
...@@ -17,13 +17,13 @@ spring: ...@@ -17,13 +17,13 @@ spring:
jdbc: jdbc:
time_zone: UTC time_zone: UTC
application: application:
name: fda-authentication-service name: authentication-service
cloud: cloud:
loadbalancer.ribbon.enabled: false loadbalancer.ribbon.enabled: false
mail: mail:
default-encoding: UTF-8 default-encoding: UTF-8
host: mail.student.tuwien.ac.at host: "${SMTP_HOST}"
port: 993 port: "${SMTP_PORT}"
username: "${SMTP_USERNAME}" username: "${SMTP_USERNAME}"
password: "${SMTP_PASSWORD}" password: "${SMTP_PASSWORD}"
properties.mail.smtp: properties.mail.smtp:
...@@ -40,17 +40,17 @@ logging: ...@@ -40,17 +40,17 @@ logging:
org.springframework.mail.: debug org.springframework.mail.: debug
org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug
eureka: eureka:
instance.hostname: localhost instance.hostname: authentication-service
client.serviceUrl.defaultZone: http://localhost:9090/eureka/ client.serviceUrl.defaultZone: http://discovery-service:9090/eureka/
fda: fda:
ready.path: ./ready ready.path: /ready
website: http://localhost:3000 website: "${WEBSITE}"
gateway.endpoint: http://localhost:9095 gateway.endpoint: "${GATEWAY_ENDPOINT}"
mail: mail:
prefix: / prefix: /
from: Database Repository <noreply@dbrepo.ossdip.at> from: "${MAIL_FROM}"
replyto: Martin Weise <martin.weise@tuwien.ac.at> replyto: "${MAIL_REPLY_TO}"
jwt: jwt:
issuer: fda-dbrepo issuer: "${JWT_ISSUER}"
secret: fda-secret secret: "${JWT_SECRET}"
expiration.ms: 86400000 # 24 hrs expiration.ms: "${JWT_EXPIRATION}" # 24 hrs
\ No newline at end of file \ No newline at end of file
...@@ -20,6 +20,14 @@ RUN mvn -q clean package -DskipTests > /dev/null ...@@ -20,6 +20,14 @@ RUN mvn -q clean package -DskipTests > /dev/null
###### THIRD STAGE ###### ###### THIRD STAGE ######
FROM rabbitmq:3-management-alpine FROM rabbitmq:3-management-alpine
ENV METADATA_DB=fda
ENV METADATA_USERNAME=postgres
ENV METADATA_PASSWORD=postgres
ENV BROKER_USERNAME=fda
ENV BROKER_PASSWORD=fda
ENV RABBITMQ_DEFAULT_USER=fda
ENV RABBITMQ_DEFAULT_PASS=fda
RUN apk --no-cache add openjdk11 RUN apk --no-cache add openjdk11
COPY ./service_ready /usr/bin COPY ./service_ready /usr/bin
......
# user # user
default_vhost = / default_vhost = /
default_user = fda
default_pass = fda
default_user_tags.administrator = true default_user_tags.administrator = true
default_permissions.configure = .* default_permissions.configure = .*
default_permissions.read = .* default_permissions.read = .*
......
...@@ -13,11 +13,11 @@ spring: ...@@ -13,11 +13,11 @@ spring:
jdbc: jdbc:
time_zone: UTC time_zone: UTC
application: application:
name: fda-broker-service name: "${BROKER_HOSTNAME}"
rabbitmq: rabbitmq:
host: fda-broker-service host: "${BROKER_HOSTNAME}"
username: fda username: "${BROKER_USERNAME}"
password: fda password: "${BROKER_PASSWORD}"
cloud: cloud:
loadbalancer.ribbon.enabled: false loadbalancer.ribbon.enabled: false
server: server:
...@@ -29,7 +29,7 @@ logging: ...@@ -29,7 +29,7 @@ logging:
at.tuwien.: debug at.tuwien.: debug
org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug
eureka: eureka:
instance.hostname: fda-broker-service instance.hostname: "${BROKER_HOSTNAME}"
client.serviceUrl.defaultZone: http://fda-discovery-service:9090/eureka/ client.serviceUrl.defaultZone: http://fda-discovery-service:9090/eureka/
fda: fda:
ready.path: /ready ready.path: /ready
......
...@@ -13,11 +13,11 @@ spring: ...@@ -13,11 +13,11 @@ spring:
jdbc: jdbc:
time_zone: UTC time_zone: UTC
application: application:
name: fda-broker-service name: broker-service
rabbitmq: rabbitmq:
host: localhost host: broker-service
username: fda username: "${BROKER_USERNAME}"
password: fda password: "${BROKER_PASSWORD}"
cloud: cloud:
loadbalancer.ribbon.enabled: false loadbalancer.ribbon.enabled: false
server: server:
...@@ -29,8 +29,8 @@ logging: ...@@ -29,8 +29,8 @@ logging:
at.tuwien.: debug at.tuwien.: debug
org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug
eureka: eureka:
instance.hostname: localhost instance.hostname: broker-service
client.serviceUrl.defaultZone: http://localhost:9090/eureka/ client.serviceUrl.defaultZone: http://discovery-service:9090/eureka/
fda: fda:
ready.path: ./ready ready.path: ./ready
gateway.endpoint: http://localhost:9095 gateway.endpoint: http://gateway-service:9095
\ No newline at end of file \ No newline at end of file
...@@ -21,6 +21,12 @@ RUN mvn -q clean package -DskipTests > /dev/null ...@@ -21,6 +21,12 @@ RUN mvn -q clean package -DskipTests > /dev/null
###### THIRD STAGE ###### ###### THIRD STAGE ######
FROM openjdk:11-jre-slim as runtime FROM openjdk:11-jre-slim as runtime
ENV METADATA_DB=fda
ENV METADATA_USERNAME=postgres
ENV METADATA_PASSWORD=postgres
ENV BROKER_USERNAME=fda
ENV BROKER_PASSWORD=fda
COPY ./service_ready /usr/bin COPY ./service_ready /usr/bin
RUN chmod +x /usr/bin/service_ready RUN chmod +x /usr/bin/service_ready
......
...@@ -2,7 +2,7 @@ app.version: '@project.version@' ...@@ -2,7 +2,7 @@ app.version: '@project.version@'
spring: spring:
main.banner-mode: off main.banner-mode: off
datasource: datasource:
url: jdbc:postgresql://localhost:5432/fda url: "jdbc:postgresql://metadata-db:5432/${METADATA_DB}"
driver-class-name: org.postgresql.Driver driver-class-name: org.postgresql.Driver
username: postgres username: postgres
password: postgres password: postgres
...@@ -17,7 +17,7 @@ spring: ...@@ -17,7 +17,7 @@ spring:
jdbc: jdbc:
time_zone: UTC time_zone: UTC
application: application:
name: fda-container-service name: container-service
cloud: cloud:
loadbalancer.ribbon.enabled: false loadbalancer.ribbon.enabled: false
springdoc.swagger-ui.enabled: true springdoc.swagger-ui.enabled: true
...@@ -29,9 +29,9 @@ logging: ...@@ -29,9 +29,9 @@ logging:
at.tuwien.: debug at.tuwien.: debug
org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug
eureka: eureka:
instance.hostname: fda-container-service instance.hostname: container-service
client.serviceUrl.defaultZone: http://localhost:9090/eureka/ client.serviceUrl.defaultZone: http://discovery-service:9090/eureka/
fda: fda:
mount.path: /tmp mount.path: /tmp
ready.path: ./ready ready.path: /ready
gateway.endpoint: "${GATEWAY_ENDPOINT}" gateway.endpoint: http://gateway-service:9095
\ No newline at end of file \ No newline at end of file
...@@ -21,6 +21,14 @@ RUN mvn -q clean package -DskipTests > /dev/null ...@@ -21,6 +21,14 @@ RUN mvn -q clean package -DskipTests > /dev/null
###### THIRD STAGE ###### ###### THIRD STAGE ######
FROM openjdk:11-jre-slim as runtime FROM openjdk:11-jre-slim as runtime
ENV METADATA_DB=fda
ENV METADATA_USERNAME=postgres
ENV METADATA_PASSWORD=postgres
ENV BROKER_USERNAME=fda
ENV BROKER_PASSWORD=fda
ENV SEARCH_ENDPOINT=search-service
ENV GATEWAY_ENDPOINT=http://gateway-service:9095
COPY ./service_ready /usr/bin COPY ./service_ready /usr/bin
RUN chmod +x /usr/bin/service_ready RUN chmod +x /usr/bin/service_ready
......
...@@ -22,8 +22,8 @@ spring: ...@@ -22,8 +22,8 @@ spring:
loadbalancer.ribbon.enabled: false loadbalancer.ribbon.enabled: false
rabbitmq: rabbitmq:
host: fda-broker-service host: fda-broker-service
username: fda username: "${BROKER_USERNAME}"
password: fda password: "${BROKER_PASSWORD}"
server.port: 9092 server.port: 9092
logging: logging:
pattern.console: "%d %highlight(%-5level) %msg%n" pattern.console: "%d %highlight(%-5level) %msg%n"
......
...@@ -2,39 +2,39 @@ app.version: '@project.version@' ...@@ -2,39 +2,39 @@ app.version: '@project.version@'
spring: spring:
main.banner-mode: off main.banner-mode: off
datasource: datasource:
url: jdbc:postgresql://localhost:5432/fda url: "jdbc:postgresql://metadata-db:5432/${METADATA_DB}"
driver-class-name: org.postgresql.Driver driver-class-name: org.postgresql.Driver
username: postgres username: "${METADATA_USERNAME}"
password: postgres password: "${METADATA_PASSWORD}"
jpa: jpa:
show-sql: true show-sql: false
database-platform: org.hibernate.dialect.PostgreSQLDialect database-platform: org.hibernate.dialect.PostgreSQLDialect
hibernate: hibernate:
ddl-auto: update ddl-auto: validate
open-in-view: false open-in-view: false
properties: properties:
hibernate: hibernate:
jdbc: jdbc:
time_zone: UTC time_zone: UTC
application: application:
name: fda-database-service name: database-service
cloud: cloud:
loadbalancer.ribbon.enabled: false loadbalancer.ribbon.enabled: false
rabbitmq: rabbitmq:
host: localhost host: broker-service
username: fda username: "${BROKER_USERNAME}"
password: fda password: "${BROKER_PASSWORD}"
server.port: 9092 server.port: 9092
logging: logging:
pattern.console: "%d %highlight(%-5level) %msg%n" pattern.console: "%d %highlight(%-5level) %msg%n"
level: level:
root: warn root: warn
at.tuwien.: trace at.tuwien.: debug
org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver: debug
eureka: eureka:
instance.hostname: fda-database-service instance.hostname: database-service
client.serviceUrl.defaultZone: http://localhost:9090/eureka/ client.serviceUrl.defaultZone: http://discovery-service:9090/eureka/
fda: fda:
elastic.endpoint: "${SEARCH_ENDPOINT}" elastic.endpoint: search-service:9200
ready.path: ./ready ready.path: /ready
gateway.endpoint: "${GATEWAY_ENDPOINT}" gateway.endpoint: http://gateway-service:9095
\ No newline at end of file \ No newline at end of file
...@@ -15,6 +15,10 @@ RUN mvn -q clean package -DskipTests > /dev/null ...@@ -15,6 +15,10 @@ RUN mvn -q clean package -DskipTests > /dev/null
###### SECOND STAGE ###### ###### SECOND STAGE ######
FROM openjdk:11-jre-slim as runtime FROM openjdk:11-jre-slim as runtime
ENV METADATA_DB=fda
ENV METADATA_USERNAME=postgres
ENV METADATA_PASSWORD=postgres
COPY ./service_ready /usr/bin COPY ./service_ready /usr/bin
RUN chmod +x /usr/bin/service_ready RUN chmod +x /usr/bin/service_ready
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment