Skip to content

Commit

Permalink
Fixed error in publish lambda GHA
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronaldo Macapobre committed Nov 13, 2024
1 parent 7e8c235 commit 40113ca
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/actions/deploy-lambda/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ inputs:
app_name:
description: The application name.
required: true
resource:
description: The resource path of the lambda function.
required: true
lambda_name:
description: The lambda function name name.
required: true
Expand Down Expand Up @@ -71,7 +68,7 @@ runs:
id: ecr-check
shell: bash
run: |
IMAGE_TAG=${{ inputs.resource }}${{ inputs.lambda_name }}-${{ inputs.short_sha }}
IMAGE_TAG=${{ inputs.lambda_name }}-${{ inputs.short_sha }}
REPOSITORY_NAME=${{ inputs.app_name }}-lambda-repo-${{ inputs.environment }}
IMAGE_EXISTS=$(aws ecr describe-images --repository-name $REPOSITORY_NAME --query "imageDetails[?contains(imageTags, '$IMAGE_TAG')]" --output text)
Expand Down
7 changes: 3 additions & 4 deletions .github/workflows/publish-lambdas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
LAMBDA_DIR_LIST=$(echo "${LAMBDA_DIRS}" | jq -R 'split(";")' -c)
echo "LAMBDA_DIR_LIST=$LAMBDA_DIR_LIST" >> $GITHUB_OUTPUT
deploy-to-gchr:
deploy2gchr:
needs: get-lambdas
environment: ${{ inputs.environment }}
permissions:
Expand Down Expand Up @@ -121,7 +121,7 @@ jobs:
deploy2dev:
name: Deploy to DEV
needs: [get-lambdas, deploy-to-gchr]
needs: [get-lambdas, deploy2gchr]
env:
ENVIRONMENT: dev
permissions:
Expand Down Expand Up @@ -157,7 +157,6 @@ jobs:
aws_role_arn: ${{ vars.AWS_ROLE_ARN }}
ghcr_token: ${{ secrets.GITHUB_TOKEN }}
github_image_repo: ${{ env.GITHUB_IMAGE_REPO }}
resource: ${{ env.RESOURCE }}
lambda_name: ${{ env.LAMBDA }}
image_name: ${{ env.RESOURCE }}.${{ env.LAMBDA }}
short_sha: ${{ needs.deploy-to-gchr.outputs.short_sha }}
short_sha: ${{ needs.deploy2gchr.outputs.short_sha }}

0 comments on commit 40113ca

Please sign in to comment.