From 26d75e31b486d013d591b7cc637841985078b478 Mon Sep 17 00:00:00 2001 From: Sarah Parker Date: Tue, 30 Jul 2024 08:42:27 -0400 Subject: [PATCH] added need step --- .github/workflows/main.yaml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 8e47979..698f196 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -53,6 +53,7 @@ jobs: docker push $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG deploy: name: Deploy to EKS + needs: [build-api, build-frontend] runs-on: arc-runner-set steps: - name: Checkout @@ -63,30 +64,25 @@ jobs: aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} aws-region: ${{secrets.AWS_REGION}} - - name: Install curl + - name: Install curl and unzip run: | - echo "installing curl..." sudo apt-get update sudo apt-get install -y curl unzip - name: Intall Helm run: | - echo "installing helm..." curl -fsSL -o get_helm.sh https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 chmod 700 get_helm.sh ./get_helm.sh - name: Install AWS CLI run: | - echo "installing aws cli..." curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" unzip awscliv2.zip sudo ./aws/install - name: Configure Kubectl run: | - echo "configuring kubectl" aws eks update-kubeconfig --name ${{secrets.K8S_CLUSTER_NAME}} --region ${{secrets.AWS_REGION}} - name: Install/Update Helm Chart run: | - echo "installing/updating helm chart..." helm upgrade --install todo-app ./todo --set database.host=${{secrets.DB_HOST}} --set database.username=${{secrets.DB_USERNAME}} --set database.password=${{secrets.DB_PASSWORD}} --set api.image.repository=${{secrets.API_IMAGE_URI}} --set frontend.image.repository=${{secrets.FRONTEND_IMAGE_URI}}