appleboy / lambda-action

GitHub Action for Deploying Lambda code to an existing function

Home Page:https://github.com/marketplace/actions/aws-lambda-deploy

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Change in behaviour when updating a lambda using this action

tiago-loureiro opened this issue · comments

I have been using this action since the october version without any problems; however, a current change in the behaviour of this action has caused my deployments to suddenly fail.

I looked through the work done in the past days and there seems to be a behavioural change related to environment variables: this worked very well for me because I managed the rest of the environment with terraform, i.e., the env variables are managed separately.

Previously, it was not possible to set any environment variables and since this version this seems to be possible; this is not really a problem (I think it's a great solution) the issue is that if I specify nothing as environment, the action overrides my variables and I end up with a single variable DRONE_COMMIT. Not sure that this drone lambda commit commit is the culprit, my Go skills are not the best :)

What I'd like to know is:

  • Was it intentional to remove environment variables from the lambda if you set none? It is not clear to me looking at the PR descriptions.
  • If it was intentional, can we add another setting such as removeOtherVariables: false or similar? Or simply do not touch environment variables if nothing is set?

Thanks!

I am also having this issue using @ master and @v0.1.5. Environment variables set in the Cloud Formation script are removed. Environment variables set with the Environment setting are not applied. All I get is the DRONE_COMMIT variable.

I will take it.

I will bump the new version.