From 3bb8c177249d0accf5df3b8004daa3dbc281e020 Mon Sep 17 00:00:00 2001 From: JivusAyrus Date: Tue, 3 Sep 2024 03:40:42 +0530 Subject: [PATCH] chore: update ci.yml --- .github/workflows/ci.yml | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ed298f8..cadbe78 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,8 +41,7 @@ jobs: - run: | echo "${{ steps.ff.outputs.feature_subgraphs_to_deploy }}" - - name: Setup Flyctl - run: curl -L https://fly.io/install.sh | sh + - uses: superfly/flyctl-actions/setup-flyctl@master - name: Deploy apps to Fly.io env: @@ -86,8 +85,7 @@ jobs: echo "${{ steps.ff.outputs.feature_subgraphs_to_deploy }}" echo "${{ steps.ff.outputs.feature_subgraphs_to_destroy }}" - - name: Setup Flyctl - run: curl -L https://fly.io/install.sh | sh + - uses: superfly/flyctl-actions/setup-flyctl@master - name: Deploy or update apps on Fly.io env: @@ -105,7 +103,7 @@ jobs: fi done - echo '${{ steps.ff.outputs.feature_subgraphs_to_deploy }}' | jq -c '.[]' | while read -r subgraph; do + echo '${{ steps.ff.outputs.feature_subgraphs_to_destroy }}' | jq -c '.[]' | while read -r subgraph; do name=$(echo "$subgraph" | jq -r '.featureSubgraphName') flyctl apps destroy $name --yes done @@ -141,14 +139,13 @@ jobs: - run: | echo "${{ steps.ff.outputs.feature_subgraphs_to_destroy }}" - - name: Setup Flyctl - run: curl -L https://fly.io/install.sh | sh + - uses: superfly/flyctl-actions/setup-flyctl@master - name: Destroy apps on Fly.io env: FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} run: | - echo '${{ steps.ff.outputs.feature_subgraphs_to_deploy }}' | jq -c '.[]' | while read -r subgraph; do + echo '${{ steps.ff.outputs.feature_subgraphs_to_destroy }}' | jq -c '.[]' | while read -r subgraph; do name=$(echo "$subgraph" | jq -r '.featureSubgraphName') flyctl apps destroy $name --yes done