Skip to content

fix(AWS Local Invocation): Ensure env vars resolve for docker#10962

Merged
pgrzesik merged 1 commit into
serverless:mainfrom
SerheyDolgushev:fix-rust-resolve-env-vars
Apr 13, 2022
Merged

fix(AWS Local Invocation): Ensure env vars resolve for docker#10962
pgrzesik merged 1 commit into
serverless:mainfrom
SerheyDolgushev:fix-rust-resolve-env-vars

Conversation

@SerheyDolgushev

Copy link
Copy Markdown
Contributor

Steps to reproduce

  1. Clone the latest https://github.com/SerheyDolgushev/serverless-rust-example:

    git clone [email protected]:SerheyDolgushev/serverless-rust-example.git
    cd serverless-rust-example
  2. Install Node.js dependencies:

    npm install --only=dev
  3. Run get_variable action for AccountElasticsearchDomainEndpoint variable:

    npx serverless invoke local -f hello -d '{"action": "get_variable", "name": "AccountElasticsearchDomainEndpoint"}'

Actual result

{"name":"AccountElasticsearchDomainEndpoint","value":"[object Object]"}

Expected result

{"name":"AccountElasticsearchDomainEndpoint","value":"search-account-test-24zc7k4nrcwra44odfw7jy4v44.us-east-1.es.amazonaws.com"}

@SerheyDolgushev

Copy link
Copy Markdown
Contributor Author

@pgrzesik please have a look whenever you will have a chance.

@codecov

codecov Bot commented Apr 12, 2022

Copy link
Copy Markdown

Codecov Report

Merging #10962 (274bf14) into main (89a92a3) will increase coverage by 0.00%.
The diff coverage is 41.66%.

@@           Coverage Diff           @@
##             main   #10962   +/-   ##
=======================================
  Coverage   86.38%   86.38%           
=======================================
  Files         305      305           
  Lines       12947    12948    +1     
=======================================
+ Hits        11184    11185    +1     
  Misses       1763     1763           
Impacted Files Coverage Δ
lib/plugins/aws/invoke-local/index.js 70.25% <41.66%> (+0.07%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 89a92a3...274bf14. Read the comment docs.

@pgrzesik pgrzesik left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot @SerheyDolgushev - great catch 👍

@pgrzesik pgrzesik changed the title fix(AWS Local Invocation): resolve configured environment variables for rust func fix(AWS Local Invocation): Ensure env vars resolve for docker Apr 13, 2022
@pgrzesik
pgrzesik merged commit 1a8e7d9 into serverless:main Apr 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants