diff --git a/create b/run similarity index 55% rename from create rename to run index 55b960b..56e79d0 100755 --- a/create +++ b/run @@ -1,8 +1,12 @@ #!/usr/bin/env bash +docker stop passwd0 +docker rm passwd0 +docker stop passwd-db +docker rm passwd-db docker build -t passwd0 . docker network create passwd-db docker run -d --restart always --name passwd-db --network passwd-db \ -v "$PWD/db":/var/lib/postgresql/data postgres:10.5-alpine -docker run -d --restart always --name passwd0 --network passwd-db \ +docker run -d --restart always --name passwd0 --network web \ passwd0:latest -docker network connect web passwd0 +docker network connect passwd-db passwd0