Skip to content

troubleshooting

troubleshooting #2

Workflow file for this run

name: Release workflow
on:
push:
branches: troubleshoot-eks
#release:
# types: [published]
env:
IMAGE_NAME: samanthamorris684/catbot
EKS_CLUSTER_NAME: catbot-cluster
jobs:
build-push-deploy-image:
name: Build and push image then deploy to EKS
runs-on: ubuntu-latest
steps:
- name: Check out repo
uses: actions/checkout@v4
- name: Build and push to Docker Hub
uses: ./.github/workflows/build-and-push.yml
with:
IMAGE_TAG: $GITHUB_SHA
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Update kube config
run: aws eks update-kubeconfig --name ${{ env.EKS_CLUSTER_NAME }} --region ${{ secrets.AWS_REGION }}
- name: Deploy to EKS
run: |
kubectl set image deployment/server samanthamorris684/catbot=samanthamorris684/catbot:$GITHUB_SHA
kubectl rollout status deployment/server