[infra] - upgrading dockerfiles #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Continuos Delivery - CD | ||
on: | ||
# workflow_run: | ||
# workflows: ["Continuos Integration - CI"] | ||
# types: | ||
# - requested | ||
workflow_dispatch: | ||
jobs: | ||
aws: | ||
runs-on: self-hosted | ||
# steps: | ||
# - name: Stoping Containers | ||
# - run: | | ||
# sudo docker stop knockbank-web || true | ||
# sudo docker rm -f knockbank-web || true | ||
# sudo docker image rm -f davilucciola/knockbank-web || true | ||
# sudo docker stop knockbank-api || true | ||
# sudo docker rm -f knockbank-api || true | ||
# sudo docker image rm -f davilucciola/knockbank-api || true | ||
# - name: Pull Docker Images | ||
# run: | | ||
# sudo docker pull davilucciola/knockbank-api:latest | ||
# sudo docker pull davilucciola/knockbank-web:latest | ||
# - name: Running API Container | ||
# env: | ||
# TOKEN_SECRET: ${{ secrets.TOKEN_SECRET }} | ||
# SQLALCHEMY_DATABASE_URI: ${{ secrets.SQLALCHEMY_DATABASE_URI }} | ||
# run: | | ||
# sudo docker run --name knockbank-api -p 5000:5000 --restart=always \ | ||
# -e TOKEN_SECRET=$TOKEN_SECRET \ | ||
# -e SQLALCHEMY_DATABASE_URI=$SQLALCHEMY_DATABASE_URI \ | ||
# -d davilucciola/knockbank-api | ||
# - name: Running Web Container | ||
# env: | ||
# run: | | ||
# sudo docker run --name knockbank-web -p 3000:3000 --restart=always \ | ||
# -d davilucciola/knockbank-web |