Skip to content

Commit

Permalink
debug-1
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelxswe committed Apr 2, 2024
1 parent ae1a79c commit e08a79f
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: CICD

on:
push:
branches: [ "main" ]
branches: ["main"]
pull_request:
branches: [ "main" ]
branches: ["main"]

workflow_dispatch:

Expand Down Expand Up @@ -69,7 +69,7 @@ jobs:
run: |
cd tests/integration/
pytest -v --cov
deploy-infrastructure:
needs: integration-test
runs-on: ubuntu-latest
Expand All @@ -90,14 +90,14 @@ jobs:
--template-file infrastructure/cf.yml \
--stack-name test-stack \
--no-fail-on-empty-changeset \
build-and-push-image:
needs: deploy-infrastructure
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3

- name: Set up AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
Expand All @@ -106,22 +106,22 @@ jobs:
aws-region: us-east-1

- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v1

- name: Build, tag, and push image to Amazon ECR
env:
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
ECR_REPOSITORY: test
IMAGE_TAG: latest
run: |
ECR_REGISTRY=${{ steps.login-ecr.outputs.registry }}
ECR_REPOSITORY=test
IMAGE_TAG=latest
IMAGE_NAME=app
IMAGE_URI="${ECR_REGISTRY}/${ECR_REPOSITORY}:${IMAGE_TAG}"
# IMAGE_URI="${ECR_REGISTRY}/${ECR_REPOSITORY}:${IMAGE_TAG}"
echo $ECR_REGISTRY
echo $IMAGE_URI
echo $IMAGE_NAME
ehco $ECR_REPOSITORY
echo $IMAGE_TAG
docker build -t $IMAGE_NAME .
docker tag $IMAGE_NAME:$IMAGE_TAG $IMAGE_URI
docker push $IMAGE_URI
# docker build -t $IMAGE_NAME .
# docker tag $IMAGE_NAME:$IMAGE_TAG $IMAGE_URI
# docker push $IMAGE_URI
# run: |
# ECR_REPOSITORY=test
Expand Down

0 comments on commit e08a79f

Please sign in to comment.