From 4a79cefdf5d71715b6c575d5c8bb4fea418c2ba6 Mon Sep 17 00:00:00 2001 From: Georgios Andreadis Date: Mon, 29 Jun 2020 16:06:35 +0200 Subject: Prepare opendc repository for monorepo This change prepares the opendc repository for a monorepo setup by moving all files to the core/ directory. After all repositories have been merged into this repository, we will move the correct files back. --- core/docker-compose.yml | 84 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 core/docker-compose.yml (limited to 'core/docker-compose.yml') diff --git a/core/docker-compose.yml b/core/docker-compose.yml new file mode 100644 index 00000000..3f4ad20a --- /dev/null +++ b/core/docker-compose.yml @@ -0,0 +1,84 @@ +version: "3" +services: + frontend: + build: ./ + image: frontend + restart: on-failure + ports: + - "8081:8081" + links: + - mariadb + depends_on: + - mariadb + environment: + - MYSQL_DATABASE=opendc + - MYSQL_USER=opendc + - MYSQL_PASSWORD=opendcpassword + - MONGO_DB=opendc + - MONGO_DB_USERNAME=opendc + - MONGO_DB_PASSWORD=opendcpassword + - MONGO_DB_HOST=mongo + - MONGO_DB_PORT=27017 + + simulator: + build: + context: ./opendc-simulator + dockerfile: opendc-model-odc/setup/Dockerfile + image: simulator + restart: on-failure + links: + - mariadb + depends_on: + - mariadb + environment: + - PERSISTENCE_URL=jdbc:mysql://mariadb:3306/opendc + - PERSISTENCE_USER=opendc + - PERSISTENCE_PASSWORD=opendcpassword + - COLLECT_MACHINE_STATES=ON + - COLLECT_TASK_STATES=ON + - COLLECT_STAGE_MEASUREMENTS=OFF + - COLLECT_TASK_METRICS=OFF + - COLLECT_JOB_METRICS=OFF + mariadb: + build: + context: ./database + image: database + restart: on-failure + ports: + - "3306:3306" # comment this line out in production + environment: + - MYSQL_DATABASE=opendc + - MYSQL_USER=opendc + - MYSQL_PASSWORD=opendcpassword + - MYSQL_RANDOM_ROOT_PASSWORD=yes + # uncomment in production + # volumes: + # - "/data/mariadb:/var/lib/mysql" + mongo: + build: + context: ./mongodb + restart: on-failure + environment: + - MONGO_INITDB_ROOT_USERNAME=root + - MONGO_INITDB_ROOT_PASSWORD=rootpassword + - MONGO_INITDB_DATABASE=admin + - OPENDC_DB=opendc + - OPENDC_DB_USERNAME=opendc + - OPENDC_DB_PASSWORD=opendcpassword + ports: + - 27017:27017 + #volumes: + # - mongo-volume:/data/db + + mongo-express: + image: mongo-express + restart: on-failure + ports: + - 8082:8081 + environment: + ME_CONFIG_MONGODB_ADMINUSERNAME: root + ME_CONFIG_MONGODB_ADMINPASSWORD: rootpassword + +volumes: + mongo-volume: + external: false \ No newline at end of file -- cgit v1.2.3