{"id":35253021,"url":"https://github.com/localstack/localstack-dagger-module","last_synced_at":"2026-04-10T10:02:56.310Z","repository":{"id":287059938,"uuid":"961860324","full_name":"localstack/localstack-dagger-module","owner":"localstack","description":"A Dagger module for running LocalStack  as a service within your Dagger pipelines.","archived":false,"fork":false,"pushed_at":"2026-03-23T12:01:16.000Z","size":382,"stargazers_count":3,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-03-24T08:48:37.984Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/localstack.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-04-07T09:25:21.000Z","updated_at":"2026-03-23T11:12:37.000Z","dependencies_parsed_at":"2025-04-09T19:32:31.987Z","dependency_job_id":"e70dd24c-f61e-4d8c-bd30-17ff5fa1f98e","html_url":"https://github.com/localstack/localstack-dagger-module","commit_stats":null,"previous_names":["localstack/localstack-dagger-module"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/localstack/localstack-dagger-module","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack%2Flocalstack-dagger-module","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack%2Flocalstack-dagger-module/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack%2Flocalstack-dagger-module/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack%2Flocalstack-dagger-module/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/localstack","download_url":"https://codeload.github.com/localstack/localstack-dagger-module/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/localstack%2Flocalstack-dagger-module/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31637748,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-10T07:40:12.752Z","status":"ssl_error","status_checked_at":"2026-04-10T07:40:11.664Z","response_time":98,"last_error":"SSL_read: 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":"2025-12-30T07:05:17.286Z","updated_at":"2026-04-10T10:02:56.302Z","avatar_url":"https://github.com/localstack.png","language":"Python","readme":"# LocalStack Dagger Module\n\n[![License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](LICENSE)\n[![LocalStack Dagger Module Tests](https://github.com/localstack/localstack-dagger-module/actions/workflows/test.yml/badge.svg)](https://github.com/localstack/localstack-dagger-module/actions/workflows/test.yml)\n\nA [Dagger](https://dagger.io/) module for running [LocalStack](https://github.com/localstack/localstack) as a service within your Dagger pipelines.\n\nThis module simplifies integrating LocalStack into your development and testing workflows by:\n\n-   Starting LocalStack as a Dagger service.\n-   Securely handling LocalStack Auth Tokens using Dagger secrets.\n-   Automatically exposing standard LocalStack ports (`4566` and `443`).\n-   Allowing customization of the LocalStack container via environment variables.\n-   Optionally mounting the Docker socket for tests interacting with external containers.\n-   Managing LocalStack state using [Cloud Pods](https://docs.localstack.cloud/user-guide/state-management/cloud-pods/) (`save`/`load`/`reset`).\n-   Managing [LocalStack Ephemeral Instances](https://docs.localstack.cloud/user-guide/cloud-sandbox/ephemeral-instance/) (`create`/`list`/`delete`/`logs`).\n\n## Prerequisites\n\n-   [Dagger CLI installed](https://docs.dagger.io/install)\n-   Docker or a compatible container runtime\n-   LocalStack Auth Token (required)\n\n## Installation\n\nYou can install this module locally to use it in your own Dagger projects or pipelines:\n\n```bash\ndagger install github.com/localstack/localstack-dagger-module\n```\n\nYou can then call its functions from the Dagger CLI or your Dagger SDK code.\n\n## Usage\n\n### Start LocalStack\n\n```bash\n# 1. Set your LocalStack auth token as an environment variable\nexport LOCALSTACK_AUTH_TOKEN=\"your-token\"\n\n# 2. Start LocalStack using the token from the environment\ndagger -m github.com/localstack/localstack-dagger-module \\\n    call start --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    up\n```\n\nLocalStack will run and be accessible at `localhost:4566` and with any integration that LocalStack supports.\n\n### Customizing LocalStack\n\nYou can pass configuration variables in the following manner:\n\n```bash\ndagger -m github.com/localstack/localstack-dagger-module call start \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --configuration='SERVICES=s3' \\\n    up\n```\n\n### Mounting Docker Socket\n\nTo run emulated AWS services that rely on a container, like Lambda or ECS, you would need to mount Docker Socket into the LocalStack container.\n\n```bash\ndagger -m github.com/localstack/localstack-dagger-module call start \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --docker-sock /var/run/docker.sock \\\n    up\n```\n\n### Managing State with Cloud Pods\n\nCloud pods are persistent state snapshots of your LocalStack instance that can easily be stored, versioned, shared, and restored.\n\n```bash\n# Set your auth token\nexport LOCALSTACK_AUTH_TOKEN=\"your-token\"\n\n# Save the current state of your running LocalStack instance to a Cloud Pod\n# Assumes you have a running instance started via 'dagger call start ... up' \n# And some cloud resources created via an integration\ndagger -m github.com/localstack/localstack-dagger-module call state \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --save=dagger-test-pod\n\n# Reset the state of the running LocalStack instance\ndagger -m github.com/localstack/localstack-dagger-module call state \\\n    --reset\n\n# Load state from a Cloud Pod into your running LocalStack instance\ndagger -m github.com/localstack/localstack-dagger-module call state \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --load=dagger-test-pod\n```\n\n### Managing Ephemeral Instances\n\nEphemeral Instances allows you to run a LocalStack instance in the cloud.\n\n```bash\n# Set your auth token\nexport LOCALSTACK_AUTH_TOKEN=\"your-token\"\n\n# Create a new Ephemeral Instance in LocalStack Cloud\ndagger -m github.com/localstack/localstack-dagger-module call ephemeral \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --operation=create \\\n    --name=my-temp-instance \\\n    --lifetime=120\n\n# List active Ephemeral Instances\ndagger -m github.com/localstack/localstack-dagger-module call ephemeral \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --operation=list\n\n# Get logs for an Ephemeral Instance\ndagger -m github.com/localstack/localstack-dagger-module call ephemeral \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --operation=logs \\\n    --name=my-temp-instance\n\n# Delete an Ephemeral Instance\ndagger -m github.com/localstack/localstack-dagger-module call ephemeral \\\n    --auth-token=env:LOCALSTACK_AUTH_TOKEN \\\n    --operation=delete \\\n    --name=my-temp-instance\n```\n\n## Inputs\n\n### `start`\n\nUsed to configure and start the main LocalStack service.\n\n| Input           | Description                                                                 | Default                        | Example                                                      |\n| --------------- | --------------------------------------------------------------------------- | ------------------------------ | ------------------------------------------------------------ |\n| `auth-token`    | LocalStack Auth Token (as Dagger `Secret`). Required.                       | Required                       | `dagger call start --auth-token=env:LOCALSTACK_AUTH_TOKEN`   |\n| `configuration` | Comma-separated `KEY=VALUE` pairs for LocalStack environment variables.     | `None`                         | `dagger call start --configuration='DEBUG=1,PERSISTENCE=1'` |\n| `docker-sock`   | Path to the Unix socket for the Docker daemon to mount into the container.  | `None`                         | `dagger call start --docker-sock=/var/run/docker.sock`       |\n| `image-name`    | Custom LocalStack Docker image name and tag.                                | `localstack/localstack:latest` | `dagger call start --image-name=localstack/snowflake:latest` |\n\n### `state`\n\nUsed to manage the state of a running LocalStack instance using Cloud Pods.\n\n| Input        | Description                                                                     | Default                      | Example                                          |\n| ------------ | ------------------------------------------------------------------------------- | ---------------------------- | ------------------------------------------------ |\n| `auth-token` | LocalStack Auth Token (as Dagger `Secret`). Required for `save` and `load`.    | `None`                       | `dagger call state --auth-token=env:LOCALSTACK_AUTH_TOKEN` |\n| `load`       | Name of the LocalStack Cloud Pod to load into the running instance.                  | `None`                       | `dagger call state --load=my-pod`                  |\n| `save`       | Name under which to save the current state as a LocalStack Cloud Pod.                | `None`                       | `dagger call state --save=my-pod`                  |\n| `reset`      | If `true`, resets the state of the running LocalStack instance.                      | `False`                      | `dagger call state --reset`                      |\n| `endpoint`   | LocalStack endpoint to connect to.                                                   | `host.docker.internal:4566`  | `dagger call state --endpoint=localhost:4566`     |\n\n### `ephemeral`\n\nUsed to manage LocalStack Ephemeral Instances in LocalStack Cloud.\n\n| Input                    | Description                                                                                                | Default   | Example                                                  |\n| ------------------------ | ---------------------------------------------------------------------------------------------------------- | --------- | -------------------------------------------------------- |\n| `auth-token`             | LocalStack Auth Token (as Dagger `Secret`). Required for all operations.                                   | Required  | `dagger call ephemeral --auth-token=env:LOCALSTACK_AUTH_TOKEN` |\n| `operation`              | Action to perform: `create`, `list`, `delete`, `logs`.                                                     | Required  | `dagger call ephemeral --operation=create`             |\n| `name`                   | Name of the ephemeral instance. Required for `create`, `delete`, `logs`.                                   | `None`    | `dagger call ephemeral --name=my-instance`             |\n| `lifetime`               | Lifetime of the instance in minutes (only for `create` operation).                                         | `60`      | `dagger call ephemeral --lifetime=120`                   |\n| `auto-load-pod`          | Name of a Cloud Pod to automatically load when the ephemeral instance starts (only for `create` operation). | `None`    | `dagger call ephemeral --auto-load-pod=my-pod`         |\n| `extension-auto-install` | Name of an extension to automatically install when the ephemeral instance starts (only for `create` operation). | `None`    | `dagger call ephemeral --extension-auto-install=my-extension --operation=create` |\n\n## Development\n\nTo contribute or make local changes to this module:\n\n1. Clone the repository:\n  ```bash\n  git clone https://github.com/localstack/localstack-dagger-module.git\n  cd localstack-dagger-module\n  ```\n2. Run `dagger develop` to set up the development environment.\n3. Make your changes, typically within the Dagger module source files (e.g., in `src/localstack/main.py`).\n4. Test your changes locally using `dagger call` as described in the sections above.\n\n## License\n\nThis project is licensed under the Apache License 2.0. See the [LICENSE](./LICENSE) file for details.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flocalstack%2Flocalstack-dagger-module","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flocalstack%2Flocalstack-dagger-module","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flocalstack%2Flocalstack-dagger-module/lists"}