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

sam deploy is ignoring environment variables configuration #2797

Closed
epastorino opened this issue Apr 8, 2021 · 1 comment
Closed

sam deploy is ignoring environment variables configuration #2797

epastorino opened this issue Apr 8, 2021 · 1 comment

Comments

@epastorino
Copy link

I'm using SAM cli v1.22 on Windows 10.
I'm just trying to declare some environment variables in my template.yaml file so they are created in my lambda function.
I have something like this:

MyFunction:
 Type: AWS::Serverless::Function
 Properties:
  CodeUri: .
  Handler: app.app
  Runtime: python3.8
  Environment:
   Variables:
    MY_VAR: some_value

sam deploy doesn't report any errors, but no environment variables show up in AWS console for this lambda function.

I was about to give up, but then I tried uninstalling the sam cli, got an older version (1.15) and tried again.
All my environment variables were created with their corresponding values.

I haven't tried other versions nor other OSs, so as far as I know, this seems to be an issue in v1.22 on Windows 10.

@epastorino
Copy link
Author

Forget about this, please.
There was another lambda function overwriting this function variables... 🤦‍♂️

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

1 participant