Skip to content

bug: The image tag '20250903.2.preview-fixfetch-url-from-single-property' already exists in the 'deployments-prod/proj_xwogefywkyuvxmapdkll' repository and cannot be overwritten because the tag is immutable. #2473

@alexpchin

Description

@alexpchin

Provide environment information

System:
OS: macOS 15.6.1
CPU: (10) arm64 Apple M4
Memory: 119.41 MB / 24.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.11.1 - ~/.nvm/versions/node/v20.11.1/bin/node
npm: 10.2.4 - ~/.nvm/versions/node/v20.11.1/bin/npm
pnpm: 10.6.2 - ~/.nvm/versions/node/v20.11.1/bin/pnpm

Describe the bug

Error: unexpected status code: 400 Bad Request {"errors":[{"code":"TAG_INVALID","message":"The image tag '20250903.2.preview-fixfetch-url-from-single-property' already exists in the 'deployments-prod/proj_xwogefywkyuvxmapdkll' repository and cannot be overwritten because the tag is immutable."}]}

I've tried to change my package with:

    # Trigger.dev only rebuilds/pushes when the trigger app changes. If you retry a deploy with an identical tree, it may reuse the exact same computed tag → ECR rejects it (immutable).
    # Get the directory where this script is located
    SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
    # Navigate to the project root (parent of scripts directory)
    PROJECT_ROOT="$(dirname "$SCRIPT_DIR")"
    # Navigate to the trigger.dev package directory
    TRIGGER_DIR="$PROJECT_ROOT/packages/trigger.dev"
    echo "🔧 Creating deploy nonce in: $TRIGGER_DIR/.deploy-nonce"
    echo "$(date -u +%Y%m%dT%H%M%S)" > "$TRIGGER_DIR/.deploy-nonce"

But I think what happens is that if you archive the preview branch and then re-push to the same branch, the numbering system starts again?

Do we need to change the date 20250903 to include time?

Reproduction repo

Difficult to setup

To reproduce

Deploy to a preview branch
Archive that preview branch
Redeploy to that preview branch (using the eu-central-1)

Additional information

No response

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