Skip to content

Commit

Permalink
Remove db_clean service from docker-compose.yml
Browse files Browse the repository at this point in the history
A race condition between these two containers was causing the database
to sometimes get cleaned after migrations had been run. Rather than hack
together scripts to track this state I'm simply removing the clean
service from the docker-compose configuration.

See also:
  * https://docs.docker.com/compose/startup-order/
  * docker/compose#374
  • Loading branch information
rpdelaney committed Apr 9, 2020
1 parent a5eeb21 commit a856678
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions docker-compose.yml
Expand Up @@ -5,16 +5,6 @@ services:
image: postgres:11.6
ports:
- 5432:5432
db_clean:
build:
context: .
dockerfile: Dockerfile.db_clean
environment:
- FLYWAY_USER=postgres
- FLYWAY_PASSWORD=
- FLYWAY_URL=jdbc:postgresql://db/postgres
depends_on:
- db
db_migrate:
build:
context: .
Expand All @@ -26,7 +16,7 @@ services:
volumes:
- ./migrations:/flyway/sql
depends_on:
- db_clean
- db
easi:
build:
context: .
Expand Down

0 comments on commit a856678

Please sign in to comment.