{"id":18573155,"url":"https://github.com/localstack-samples/localstack-on-eks","last_synced_at":"2026-01-23T13:47:04.784Z","repository":{"id":217568079,"uuid":"734488982","full_name":"localstack-samples/localstack-on-eks","owner":"localstack-samples","description":"DevOps blueprint to run LocalStack on EKS in AWS","archived":false,"fork":false,"pushed_at":"2024-04-02T01:49:46.000Z","size":1275,"stargazers_count":12,"open_issues_count":0,"forks_count":0,"subscribers_count":14,"default_branch":"main","last_synced_at":"2025-05-13T14:31:09.992Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Makefile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/localstack-samples.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-21T20:16:23.000Z","updated_at":"2025-03-11T17:48:13.000Z","dependencies_parsed_at":"2024-02-07T20:28:56.146Z","dependency_job_id":"7c359c43-aa3c-4a1e-a821-c4eaa90977a3","html_url":"https://github.com/localstack-samples/localstack-on-eks","commit_stats":null,"previous_names":["localstack-samples/localstack-on-eks"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/localstack-samples/localstack-on-eks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack-samples%2Flocalstack-on-eks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack-samples%2Flocalstack-on-eks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack-samples%2Flocalstack-on-eks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack-samples%2Flocalstack-on-eks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/localstack-samples","download_url":"https://codeload.github.com/localstack-samples/localstack-on-eks/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack-samples%2Flocalstack-on-eks/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28693331,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-23T11:01:27.039Z","status":"ssl_error","status_checked_at":"2026-01-23T11:00:26.909Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T23:08:14.239Z","updated_at":"2026-01-23T13:47:04.742Z","avatar_url":"https://github.com/localstack-samples.png","language":"Makefile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🌐 Overview\n\nThis blueprint has two solutions:\n\n1. Deploy LocalStack to AWS EKS with Fargate. \n2. Deploy LocalStack on an engineer's laptop on EKS Anywhere with Docker.\n\n[**Solution-1**](#solution-1) provides a hybrid integration environment where teams can run component/integration/system tests.\nThe solution is managed in AWS to allow for easy management of the entire platform across multiple AWS accounts. This is further subdivided into two categories: workloads that run on Fargate backend and workloads that run on EC2 backend.\n\n[**Solution-2**](#solution-2) is identical to Solution-1 but it runs on engineers laptops with EKS Anywhere. \n\nThe two solutions having nearly identical tooling allows enterprise teams to create a manageable\nsolution testing platform.\n\n### LocalStack on AWS EKS Fargate\n\nMultiple namespaces isolate testing of different solutions.\n\n![LSonEKS](./docs/design-ls-on-aws-eks.drawio.png \"LSonEKS\")\n\n### LocalStack on Engineer's Laptop with EKS Anywhere\n![LSonEKSAny](./docs/design-ls-on-eksany.drawio.png \"LSonEKSAny\")\n\n### 🔑 Key Components\n\n- **LocalStack on K8S**\n    LocalStack provides AWS Service emulation to create aan amazing DevX with powerful solution testing. \n- **Dev Container**\n    Provides standard tooling to build, deploy, and test solutions. \n- **Amazon Elastic Kubernetes Service**\n    K8S common platform for DevSecOps tooling to support unit, component, and integration testing.\n\n## Getting Started 🏁\n\nThis guide assumes that you have cloned this repository and are in the project root directory. The following steps will\nguide you through the process of building, deploying, and test Solution-1 (Solution-2 link).\nSolution-1 is not free. It will cost money to run EKS in AWS. Make sure to destroy your resources in the cleanup\nsection to control your costs.\n\n### Solution-1\n\nThis solution has the EKS cluster deployed on AWS.\n\n#### Prerequisites for Solution-1 🧰\n\n- [install Helm](https://helm.sh/docs/intro/install/)\n- [install kubectl](https://kubernetes.io/docs/tasks/tools/)\n- [install eksctl](https://eksctl.io/installation/)\n- AWS credentials for `eksctl`.\n- `export LOCALSTACK_AUTH_TOKEN=\u003cyour LocalStack auth token\u003e` added to `.env-local`.\n- [install localstack k8s operator](https://github.com/localstack/localstack-k8s-operator).\n\n#### Solution-1 Steps\n\nLet's create the AWS cluster. This blueprint builds namespaces in the format of `ls\u003cNS_NUM\u003e`. So, we're going\nto choose a namespace number for the following targets.\n\n```shell\nmake aws-create-cluster\n```\n\nLet's create a namespace `ls0` of whose resources are deployed with Fargate:\n\n```shell\nexport FARGATE_WORKLOAD=0\n# Create the namespace and the Fargate profile.\nmake aws-create-fargate-profile NS_NUM=$FARGATE_WORKLOAD\n```\n\nNow let's create a namespace `ls1` of whose resources are deployed on EC2 nodes:\n\n```shell\nexport EC2_WORKLOAD=1\n# Create the namespace for the workloads on EC2.\nmake create-namespace NS_NUM=$EC2_WORKLOAD\n```\n\nThen let's deploy Localstack on the namespace that runs its workloads on Fargate:\n\n```shell\n# Generate manifests and apply Localstack/DevPod deployments.\nmake deploy-localstack NS_NUM=$FARGATE_WORKLOAD\n\n# Exec into dev environment\nmake exec-devpod-interactive NS_NUM=$FARGATE_WORKLOAD\n```\n\nOnce inside the DevPod environment, let's clone our Localstack sample project:\n\n```shell\ngit clone https://github.com/localstack-samples/lambda-ddb.git\ncd lambda-ddb\n\nmake integ-awscdk-bootstrap\nmake integ-awscdk-deploy\nmake integ-awscdk-test\n```\n\nNow, let's deploy Localstack on the namespace that runs its workloads on EC2 nodes:\n\n```shell\n# Generate manifests and apply Localstack/DevPod deployments.\nmake deploy-localstack NS_NUM=$EC2_WORKLOAD\n\n# Exec into dev environment\nmake exec-devpod-interactive NS_NUM=$EC2_WORKLOAD\n```\n\nAnd like before, once inside the DevPod environment, let's clone our Localstack sample project:\n\n```shell\ngit clone https://github.com/localstack-samples/lambda-ddb.git\ncd lambda-ddb\n\nmake integ-awscdk-bootstrap\nmake integ-awscdk-deploy\nmake integ-awscdk-test\n```\n\nAfter the test passes, let's delete the EKS cluster from AWS:\n\n```shell\nmake deploy-cleanup NS_NUM=$FARGATE_WORKLOAD\nmake deploy-cleanup NS_NUM=$EC2_WORKLOAD\nmake aws-delete-cluster\n```\n\n### Solution-2\n\nThis solution has the EKS cluster deployed on your local machine, using the EKS anywhere plugin.\n\n#### Prerequisites for Solution-2 🧰\n\n- Locally-accessible machine.\n- [install Helm](https://helm.sh/docs/intro/install/)\n- [install kubectl](https://kubernetes.io/docs/tasks/tools/)\n- [install eksctl](https://eksctl.io/installation/)\n- [install eksanywhere plugin](https://anywhere.eks.amazonaws.com/docs/getting-started/install/)\n- [install localstack k8s operator](https://github.com/localstack/localstack-k8s-operator).\n\n#### Solution-2 Steps\n\nLet's create the AWS cluster using EKS Anywhere locally. This blueprint builds namespaces in the format of `ls\u003cNS_NUM\u003e`. So, we're going to choose a namespace number for the following targets.\n\n```shell\nmake local-create-cluster\n\n# Create the namespace.\nmake create-namespace NS_NUM=0\n\n# Generate manifests and apply Localstack/DevPod deployments.\nmake deploy-localstack NS_NUM=0\n\n# Exec into dev environment\nmake exec-devpod-interactive NS_NUM=0\n```\n\nOnce inside the DevPod environment, let's clone our Localstack sample project:\n\n```shell\ngit clone https://github.com/localstack-samples/lambda-ddb.git\ncd lambda-ddb\n\nmake integ-awscdk-bootstrap\nmake integ-awscdk-deploy\nmake integ-awscdk-test\n```\n\nAfter the test passes, let's delete the EKS cluster from the local machine:\n\n```shell\nmake deploy-cleanup NS_NUM=0\nmake local-delete-cluster\n```\n\n### Multiple Namespaces\n\nTo deploy multiple Localstack instances with their own dev environment, you can do something like this:\n\n```shell\n\nfunction create_environment () {\n    local namespace_idx=\"$1\"\n    make create-namespace NS_NUM=$namespace_idx\n    make deploy-localstack NS_NUM=$namespace_idx\n    make exec-devpod-interactive NS_NUM=$namespace_idx\n}\n\nfunction check_localstack () {\n    local namespace_idx=\"$1\"\n    make exec-devpod-noninteractive NS_NUM=$namespace_idx CMD=\"curl -i localstack$namespace_idx:4566\"\n}\n\n# Create a 100 environments\nfor i in `seq 0 100`; do\n    create_environment \"$i\"\ndone\n\n# Execute the `ls -la` command on all 1000\nfor i in `seq 0 100`; do\n    check_localstack \"$i\"\ndone\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flocalstack-samples%2Flocalstack-on-eks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flocalstack-samples%2Flocalstack-on-eks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flocalstack-samples%2Flocalstack-on-eks/lists"}