Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Questions about usage #167

Open
ismailyenigul opened this issue Aug 3, 2023 · 1 comment
Open

Questions about usage #167

ismailyenigul opened this issue Aug 3, 2023 · 1 comment

Comments

@ismailyenigul
Copy link

Hi,

I would like to test this action. But I have some questions about usage.

  1. I dont see any configuration about setting AWS Region? How does this action know the AWS region of the lambda function?
  2. Should we use just lambda function name as function-name or should we specify full arn?
  3. For Lambda function with container image use case,
    not sure but what happens if {{ steps.metadata.outputs.tags }} returns multiple tags?
    It might be good to add an example for tags in metadata-action parameters
      # deploy
      - uses: int128/deploy-lambda-action@v1
        with:
          function-name: my-function
          image-uri: ${{ steps.metadata.outputs.tags }}
          alias-name: ${{ steps.metadata.outputs.version }}
  
@ext-ricardo-filho
Copy link

ext-ricardo-filho commented Sep 12, 2023

Not an expert on the issue here, But I think that this should be set up within your aws creds configuration. also, your ecr image uri can handle the region as well:
Here's an example:

deploy-lambda-function-after-created:
    name: deploy-lambda-function-after-created
    runs-on: ubuntu-latest
    needs: image-build-and-push
    steps:
    - name: configure credentials
      uses: aws-actions/configure-aws-credentials@v1
      with:
        aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
        aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
        aws-region: ${{ vars.AWS_REGION }}
    - name: Create or update lambda image
      uses: int128/deploy-lambda-action@v1
      with:
        function-name: my-awesome-func-name
        image-uri: ${{ vars.AWS_ACCOUNT_ID }}.dkr.ecr.${{ vars.AWS_REGION }}.amazonaws.com/${{ vars.ECR_REPO_NAME }}:latest
        alias-name: farmarcas-production-collector-webservice

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants