Skip to content

Commit

Permalink
Update cicd.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
akannan1087 authored Apr 9, 2024
1 parent 7e5b735 commit 6475523
Showing 1 changed file with 6 additions and 16 deletions.
22 changes: 6 additions & 16 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Login to Docker Hub
uses: docker/login-action@v3
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
env:
IMAGE_TAG: ${{ github.sha }}
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: ${{ secrets.DOCKERHUB_USERNAME }}/mypythonapp:${{ steps.meta.outputs.tags }}
role-to-assume: arn:aws:iam::211223789150:role/aws-ecr-role-feb-23
role-scope: 'region'
aws-region: us-east-1
role-duration-seconds: 900 # Adjust this value as needed

0 comments on commit 6475523

Please sign in to comment.