Skip to content

[localstack preset] LocalStack image requires authentication from March 23, 2026 #1227

Description

@HarshCasper

Hey folks 👋

I'm Harsh from the LocalStack team. Wanted to flag an upcoming change that will directly affect users of the LocalStack preset in gnomock.

What's changing: Starting March 23, 2026, localstack/localstack:latest on Docker Hub will consolidate into a single unified image that requires authentication via a LOCALSTACK_AUTH_TOKEN. The free Community image, as it exists today, will no longer be available under that tag without an auth token set.

What this means for this repo:

preset/localstack/preset.go computes the image as fmt.Sprintf("docker.io/localstack/localstack:%s", p.Version). Any user who calls gnomock.Start(&localstack.P{}) after March 23 without passing a LOCALSTACK_AUTH_TOKEN environment variable will hit an authentication error and the container will fail to start.

The places most likely to need updating:

  • preset/localstack/preset.go — the Options() method should forward LOCALSTACK_AUTH_TOKEN from the host environment to the container if present
  • README / preset docs — auth token setup should be listed as a prerequisite for the LocalStack preset

What users will need to do:

  1. Sign up for a free LocalStack account at localstack.cloud
  2. Generate an auth token from the LocalStack Web App
  3. Set LOCALSTACK_AUTH_TOKEN as an environment variable when starting the container

With gnomock, this would look like:

import (
    "os"
    "github.com/orlangure/gnomock"
    "github.com/orlangure/gnomock/preset/localstack"
)

container, err := gnomock.Start(
    &localstack.P{
        Services: []localstack.Service{localstack.S3}
    },
    gnomock.WithEnv("LOCALSTACK_AUTH_TOKEN=" + os.Getenv("LOCALSTACK_AUTH_TOKEN")),
)

The good news: A free tier is staying. CI credits are now unlimited on all plans, including free, and open-source projects can apply for free access to paid plans.

Full details in our announcements:

Happy to help with any doc updates, review PRs, or answer questions. Let us know if there's anything we can do to make this transition easier — and thanks for maintaining the LocalStack preset in gnomock! 🙏

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions