From 612801067d4bf39ef9e23c82fd185e68ae3b27de Mon Sep 17 00:00:00 2001 From: joffrey-bion Date: Tue, 9 Feb 2021 17:42:14 +0100 Subject: Add rollback workflow Resolves: https://github.com/joffrey-bion/seven-wonders/issues/91 --- .github/workflows/rollback-digitalocean.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/rollback-digitalocean.yml (limited to '.github/workflows') diff --git a/.github/workflows/rollback-digitalocean.yml b/.github/workflows/rollback-digitalocean.yml new file mode 100644 index 00000000..2224029d --- /dev/null +++ b/.github/workflows/rollback-digitalocean.yml @@ -0,0 +1,25 @@ +name: rollback-digitalocean + +on: + workflow_dispatch: {} + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v2 + + - name: Install doctl + uses: digitalocean/action-doctl@v2 + with: + token: ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }} + + - name: Setup DigitalOcean kubeconfig + run: doctl kubernetes cluster kubeconfig save --expiry-seconds 600 bro-cluster + + - name: Deploy to DigitalOcean Kubernetes + run: kubectl apply -f kubernetes/server.yml + + - name: Verify deployment + run: kubectl rollout undo --namespace seven-wonders deployment/seven-wonders -- cgit