diff options
| author | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2017-10-28 12:05:51 +0200 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2017-10-28 12:05:51 +0200 |
| commit | 42bc99f1ffe5c851d7383e437e52d53dc65ee746 (patch) | |
| tree | af835b4b3e8a18c27b9e79ab4ac0c291753398ef /docker-compose.yml | |
| parent | b142b8017028bba8c59e573390dae19ab1ff328f (diff) | |
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.
Diffstat (limited to 'docker-compose.yml')
| -rw-r--r-- | docker-compose.yml | 76 |
1 files changed, 43 insertions, 33 deletions
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" |
