Skip to content

Custom command container build steps ignore with configuration #2876

Closed

Description

Atmos version

1.225.0

Reproduction

A custom command in .atmos.d/commands.yaml contains a typed native container build step with engine: buildx, context: app, a tag, a docker-container driver, and registry cache.from / cache.to settings.

Run:

APP_IMAGE=example.invalid/demo:sha-test \
APP_IMAGE_CACHE=example.invalid/demo:buildcache \
ECR_REGISTRY=example.invalid \
atmos --use-version=1.225.0 build

With a logging docker shim first on PATH, Atmos invokes only:

docker info
docker build -f Dockerfile .

It silently drops the configured Buildx engine, context, tag, driver, and cache settings.

Expected

Custom commands should execute typed container steps through the native workflow container runner, preserving all with: settings. At a minimum, the resulting argv should contain buildx, the configured builder, --cache-from, --cache-to, tag, Dockerfile, and context.

Impact

The feature build workflow calls atmos build and atmos push, so this silently uses Docker's default builder, misses the intended ECR cache, builds the wrong context, and does not tag the deterministic deployment image.

Activity

  1. osterman commented on Aug 5, 2026

    @osterman
    MemberAuthor

    Follow-up: reproduced against the downloaded 1.225.0 executable directly, not through the --use-version wrapper. The result is still:

    docker info
    docker build -f Dockerfile .
    

    The likely gap is the Viper/mapstructure custom-command load path. Task.ToWorkflowStep() does copy Build, Driver, and Cache, but decodeTaskFromMap() decodes a Task using WorkflowStepDecodeHook(). That hook only normalizes targets of type WorkflowStep, so it does not decode the custom command's with: map into Task.Build. The conversion therefore copies a nil Build pointer and the runtime falls back to defaults.

    Please add an integration test that loads a custom command through the normal CLI configuration path (not only YAML unmarshalling or a manually populated Task), then asserts the Docker argv contains the configured Buildx engine, driver, cache, tag, Dockerfile, and context.

  2. added a commit that references this issue on Aug 5, 2026
    a7b992b
  3. added a commit that references this issue on Aug 19, 2026
    573d5aa
  4. osterman commented on Oct 8, 2026

    @osterman
    MemberAuthor

    Fixed by #2879 and released in v1.226.0. Container build steps now read the with: configuration (build, driver, cache).

    Closing. Reopen if the problem continues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions