Merge pull request #755 from andrewhsu/compose-v2

convert docker compose files to v2
This commit is contained in:
David Lawrence 2016-06-03 09:19:17 -07:00
commit 1a700552b2
2 changed files with 110 additions and 60 deletions

View File

@ -1,32 +1,61 @@
server: version: "2"
build: . services:
dockerfile: server.Dockerfile server:
links: build:
- mysql context: .
- signer dockerfile: server.Dockerfile
- signer:notarysigner networks:
entrypoint: /usr/bin/env sh mdb:
command: -c "./migrations/migrate.sh && notary-server -config=fixtures/server-config.json" sig:
signer: srv:
build: . aliases:
dockerfile: signer.Dockerfile - notary-server
links: entrypoint: /usr/bin/env sh
- mysql command: -c "./migrations/migrate.sh && notary-server -config=fixtures/server-config.json"
entrypoint: /usr/bin/env sh depends_on:
command: -c "./migrations/migrate.sh && notary-signer -config=fixtures/signer-config.json" - mysql
mysql: - signer
volumes: signer:
- ./notarymysql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d build:
image: mariadb:10.1.10 context: .
environment: dockerfile: signer.Dockerfile
- TERM=dumb networks:
- MYSQL_ALLOW_EMPTY_PASSWORD="true" mdb:
command: mysqld --innodb_file_per_table sig:
client: aliases:
volumes: - notarysigner
- ./test_output:/test_output entrypoint: /usr/bin/env sh
build: . command: -c "./migrations/migrate.sh && notary-signer -config=fixtures/signer-config.json"
dockerfile: Dockerfile depends_on:
links: - mysql
- server:notary-server mysql:
command: buildscripts/testclient.sh networks:
- mdb
volumes:
- ./notarymysql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
image: mariadb:10.1.10
environment:
- TERM=dumb
- MYSQL_ALLOW_EMPTY_PASSWORD="true"
command: mysqld --innodb_file_per_table
client:
build:
context: .
dockerfile: Dockerfile
command: buildscripts/testclient.sh
volumes:
- ./test_output:/test_output
networks:
- srv
depends_on:
- server
volumes:
notary_data:
external: false
networks:
mdb:
external: false
sig:
external: false
srv:
external: false

View File

@ -1,28 +1,49 @@
server: version: "2"
build: . services:
dockerfile: server.Dockerfile server:
links: build:
- mysql context: .
- signer dockerfile: server.Dockerfile
- signer:notarysigner networks:
ports: - mdb
- "8080" - sig
- "4443:4443" ports:
entrypoint: /usr/bin/env sh - "8080"
command: -c "./migrations/migrate.sh && notary-server -config=fixtures/server-config.json" - "4443:4443"
signer: entrypoint: /usr/bin/env sh
build: . command: -c "./migrations/migrate.sh && notary-server -config=fixtures/server-config.json"
dockerfile: signer.Dockerfile depends_on:
links: - mysql
- mysql - signer
entrypoint: /usr/bin/env sh signer:
command: -c "./migrations/migrate.sh && notary-signer -config=fixtures/signer-config.json" build:
mysql: context: .
volumes: dockerfile: signer.Dockerfile
- ./notarymysql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d networks:
- notary_data:/var/lib/mysql mdb:
image: mariadb:10.1.10 sig:
environment: aliases:
- TERM=dumb - notarysigner
- MYSQL_ALLOW_EMPTY_PASSWORD="true" entrypoint: /usr/bin/env sh
command: mysqld --innodb_file_per_table command: -c "./migrations/migrate.sh && notary-signer -config=fixtures/signer-config.json"
depends_on:
- mysql
mysql:
networks:
- mdb
volumes:
- ./notarymysql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
- notary_data:/var/lib/mysql
image: mariadb:10.1.10
environment:
- TERM=dumb
- MYSQL_ALLOW_EMPTY_PASSWORD="true"
command: mysqld --innodb_file_per_table
volumes:
notary_data:
external: false
networks:
mdb:
external: false
sig:
external: false