From 42bc99f1ffe5c851d7383e437e52d53dc65ee746 Mon Sep 17 00:00:00 2001 From: Fabian Mastenbroek Date: Sat, 28 Oct 2017 12:05:51 +0200 Subject: Sync simulator with upstream This change updates the simulator to the latest upstream version, which adds prebuilding to the Docker image and limits to simulation time. I have also added failure settings to the docker-compose configuration, in addition to slimming down the opendc Docker image configuration. --- docker-compose.yml | 76 ++++++++++++++++++++++++++++++------------------------ 1 file changed, 43 insertions(+), 33 deletions(-) (limited to 'docker-compose.yml') diff --git a/docker-compose.yml b/docker-compose.yml index d1c9c1f7..ac4bc27f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,33 +1,43 @@ -version: "2" -services: - opendc: - build: ./ - image: opendc - ports: - - "8081:8081" - links: - - mariadb - depends_on: - - mariadb - environment: - - MYSQL_DATABASE=opendc - - MYSQL_USER=opendc - - MYSQL_PASSWORD=opendcpassword - opendc-simulator: - build: ./opendc-simulator - environment: - - PERSISTENCE_URL=jdbc:mysql://mariadb:3306/opendc - - PERSISTENCE_USER=opendc - - PERSISTENCE_PASSWORD=opendcpassword - mariadb: - image: mariadb:10.1 - 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" +version: "2" +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 + simulator: + build: + context: ./opendc-simulator + dockerfile: opendc-integration-jpa/mysql/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 + mariadb: + image: mariadb:10.1 + 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" -- cgit v1.2.3