Skip to content

학기강좌검색 평점 버그 fix (#101) #46

학기강좌검색 평점 버그 fix (#101)

학기강좌검색 평점 버그 fix (#101) #46

Workflow file for this run

name: Deploy-dev
on:
push:
branches: [ develop ]
jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
env:
IMAGE_TAG: ${{ github.run_number }}
BUILD_NUMBER: ${{ github.run_number }}
ECR_REGISTRY: 405906814034.dkr.ecr.ap-northeast-2.amazonaws.com
ECR_REPOSITORY: snutt-dev/snutt-ev
ECR_BATCH_REPOSITORY: snutt-dev/snutt-ev-batch
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v2
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ap-northeast-2
- name: Login to ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v1
- name: Get and save Auth Token for CodeArtifact
id: get-save-codeartifact-auth-token
run: |
aws codeartifact get-authorization-token --domain wafflestudio --domain-owner 405906814034 --query authorizationToken --region ap-northeast-1 --output text > .codeartifact-auth-token
- name: Docker build, tag, and push image to ECR
id: build-image
run: |
docker build -t $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG . --build-arg CODEARTIFACT_AUTH_TOKEN=$(cat .codeartifact-auth-token)
docker build -f Dockerfile-batch -t $ECR_REGISTRY/$ECR_BATCH_REPOSITORY:$IMAGE_TAG . --build-arg CODEARTIFACT_AUTH_TOKEN=$(cat .codeartifact-auth-token)
docker push $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG
docker push $ECR_REGISTRY/$ECR_BATCH_REPOSITORY:$IMAGE_TAG
echo "::set-output name=image::$ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG"