summaryrefslogtreecommitdiff
path: root/.github/workflows/rollback-digitalocean.yml
blob: 3eca412168b15819fbf268ba596267fa18f29748 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
name: rollback-digitalocean

on:
  workflow_dispatch: {}

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v3.0.2

      - 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
bgstack15