diff --git a/.github/workflows/aws-cicd.yml b/.github/workflows/aws-cicd.yml index 908c468c..870fe67e 100644 --- a/.github/workflows/aws-cicd.yml +++ b/.github/workflows/aws-cicd.yml @@ -16,8 +16,8 @@ env: REGISTRY: "docker.io" NAMESPACE: "clean01" IMAGE_NAME: "layer-server" - AWS_PROD_INSTANCE_HOST: ${{ secrets.AWS_PROD_INSTANCE_HOST }} - AWS_DEV_INSTANCE_HOST: ${{ secrets.AWS_DEV_INSTANCE_HOST }} + PROD_INSTANCE_HOST: ${{ secrets.AWS_PROD_INSTANCE_HOST }} + DEV_INSTANCE_HOST: ${{ secrets.AWS_DEV_INSTANCE_HOST }} jobs: setup: @@ -30,15 +30,19 @@ jobs: host_ip: ${{ steps.set-env.outputs.HOST_IP }} # 이부분 steps: + - name: Debug Environment Variables + run: | + echo "HOST_IP: ${{ env.DEV_INSTANCE_HOST }}" + - name: Setup Env id: set-env run: | if [[ "${GITHUB_REF}" == "refs/heads/main" ]]; then echo "DEPLOY_TARGET=production" >> $GITHUB_OUTPUT - echo "HOST_IP=prod_test" >> $GITHUB_OUTPUT + echo "HOST_IP=${{ env.PROD_INSTANCE_HOST }}" >> $GITHUB_OUTPUT else echo "DEPLOY_TARGET=development" >> $GITHUB_OUTPUT - echo "HOST_IP=dev_test" >> $GITHUB_OUTPUT + echo "HOST_IP=${{ env.DEV_INSTANCE_HOST }}" >> $GITHUB_OUTPUT fi build: