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

chore: add an example of using localstack alongside AWS lambdas #1790

Merged
merged 7 commits into from
Oct 24, 2023

Conversation

mdelapenya
Copy link
Member

  • feat: expose the default labels of the library
  • fix: do not use deprecated APIs
  • chore: add an example of running localstack with Lambdas

What does this PR do?

This PR adds a testable example demonstrating how to use the localstack module to test lambdas.

To allow that, we had to improve how the core exposes the default labels, in order to add those labels to the containers used as backend of the lambdas, so Ryuk can kill them at the end of the test session.

Why is it important?

More use cases on localstack with testcontainers-go

@mdelapenya mdelapenya requested a review from a team as a code owner October 23, 2023 20:24
@mdelapenya mdelapenya added the chore Changes that do not impact the existing functionality label Oct 23, 2023
@mdelapenya mdelapenya self-assigned this Oct 23, 2023
@netlify
Copy link

netlify bot commented Oct 23, 2023

Deploy Preview for testcontainers-go ready!

Name Link
🔨 Latest commit 0f5d0ba
🔍 Latest deploy log https://app.netlify.com/sites/testcontainers-go/deploys/65377320471c4600089d7b3e
😎 Deploy Preview https://deploy-preview-1790--testcontainers-go.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

eddumelendez
eddumelendez previously approved these changes Oct 23, 2023
Copy link
Member

@eddumelendez eddumelendez left a comment

Choose a reason for hiding this comment

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

Just few notes. 👍🏽

modules/localstack/examples_test.go Outdated Show resolved Hide resolved
modules/localstack/examples_test.go Show resolved Hide resolved
@mdelapenya mdelapenya merged commit b5e9bec into testcontainers:main Oct 24, 2023
112 checks passed
@mdelapenya mdelapenya added the hacktoberfest Pull Requests accepted for Hacktoberfest. label Oct 24, 2023
mdelapenya added a commit that referenced this pull request Oct 26, 2023
* main: (27 commits)
  docs: remove OpenSSF scorecard (#1823)
  Auto-cleanup of k6 build cache (#1788)
  Add OpenSSF Scorecards GitHub Action (#1795)
  chore(deps): bump google.golang.org/grpc from 1.57.0 to 1.57.1 (#1822)
  chore: expose SessionID (#1793)
  chore: use HTTP calls to invoke the lambda from the tests (#1794)
  wait for log producer to really stop inside StopLogProducer func (#1701)
  chore(deps): bump github.com/nats-io/nats-server/v2 in /modules/nats (#1784)
  chore(deps): bump urllib3 from 2.0.6 to 2.0.7 (#1781)
  chore: add an example of using localstack alongside AWS lambdas (#1790)
  chore(deps): combine and bump compose dependencies (#1787)
  feat: support for replacing images with custom substitutions (#1719)
  fix: data race in docker client `Info()` (#1779)
  Use correct formatting directive for errors in lifecycle logs (#1780)
  chore(deps): bump golang.org/x/mod from 0.12.0 to 0.13.0 in /modules/{elasticsearch,kafka} and /modulegen (#1778)
  chore(deps): bump github.com/rabbitmq/amqp091-go in /modules/rabbitmq (#1728)
  chore(deps): bump github.com/ClickHouse/clickhouse-go/v2 (#1732)
  ignore patterns defined in dockerignore (#1725)
  Fix wrong module names (#1776)
  docs: add default options to k6 module (#1744)
  ...
mdelapenya added a commit that referenced this pull request Oct 26, 2023
…ers/image-spec-1.1.0-rc5

* main: (49 commits)
  docs: remove OpenSSF scorecard (#1823)
  Auto-cleanup of k6 build cache (#1788)
  Add OpenSSF Scorecards GitHub Action (#1795)
  chore(deps): bump google.golang.org/grpc from 1.57.0 to 1.57.1 (#1822)
  chore: expose SessionID (#1793)
  chore: use HTTP calls to invoke the lambda from the tests (#1794)
  wait for log producer to really stop inside StopLogProducer func (#1701)
  chore(deps): bump github.com/nats-io/nats-server/v2 in /modules/nats (#1784)
  chore(deps): bump urllib3 from 2.0.6 to 2.0.7 (#1781)
  chore: add an example of using localstack alongside AWS lambdas (#1790)
  chore(deps): combine and bump compose dependencies (#1787)
  feat: support for replacing images with custom substitutions (#1719)
  fix: data race in docker client `Info()` (#1779)
  Use correct formatting directive for errors in lifecycle logs (#1780)
  chore(deps): bump golang.org/x/mod from 0.12.0 to 0.13.0 in /modules/{elasticsearch,kafka} and /modulegen (#1778)
  chore(deps): bump github.com/rabbitmq/amqp091-go in /modules/rabbitmq (#1728)
  chore(deps): bump github.com/ClickHouse/clickhouse-go/v2 (#1732)
  ignore patterns defined in dockerignore (#1725)
  Fix wrong module names (#1776)
  docs: add default options to k6 module (#1744)
  ...
@mdelapenya mdelapenya deleted the localstack-lambdas branch November 6, 2023 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Changes that do not impact the existing functionality hacktoberfest Pull Requests accepted for Hacktoberfest.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants