Skip to content

Containers: Error creating application due to a misconfiguration #9846

Open
@ttrushin

Description

@ttrushin

What versions & operating system are you using?

Wrangler v4.23.0, Node v22.16.0

Please provide a link to a minimal reproduction

Not possible, but see below

Describe the Bug

I am unable to push a new container and receive the error: VALIDATE_INPUT with no added details (which might be a backend bug by itself).

However when I modify node_modules/wrangler/wrangler-dist/cli.js to include a console.log(JSON.stringify(err)) in the formatError method, I can see this in the terminal (possibly private IDs have been x'd out):

{"url":"https://api.cloudflare.com/client/v4/accounts/xxxxxxxxxxxxxxxxxxxxx/containers/applications","status":400,"statusText":"Bad Request","body":{"error":"VALIDATE_INPUT"},"request":{"method":"POST","url":"/applications","body":{"name":"1password-cli","configuration":{"image":"registry.cloudflare.com/xxxxxxxxxxxxxxxxxxxxx/onepassword-cli:1.0","observability":{"logs":{"enabled":true}},"instance_type":"dev"},"durable_objects":{"namespace_id":"xxxxxxxxxxxxxxxxxxxxx"},"instances":0,"scheduling_policy":"default","constraints":{"tier":1}},"mediaType":"application/json","errors":{"400":"Could not create the application because of input/limits reasons, more details in the error code","401":"Unauthorized","500":"There has been an internal error"}},"name":"ApiError"}

Here are the relevant sections of my wrangler.jsonc file:

{
  "$schema": "node_modules/wrangler/config-schema.json",
  "name": "xxxxxxx-xxxxxx-xxxxxx",
  "account_id": "xxxxxxxxxxxxxxxxxx",
  "main": "src/index.ts",
  "compatibility_flags": ["nodejs_compat"],
  "compatibility_date": "2025-05-10",
  "send_metrics": false,
  "minify": true,
  "upload_source_maps": true,
  "observability": {
    "enabled": true
  },
  "d1_databases": [
    {
      "binding": "DB",
      "database_name": "xxxxxxx-xxxxxx-xxxxxx",
      "database_id": "xxxxxxxxxxxxxxxxxxxxxxx"
    }
  ],
  "durable_objects": {
    "bindings": [
      {
        "name": "ONEPASSWORD_CLI_CONTAINER",
        "class_name": "OnePasswordCliContainer"
      }
    ]
  },
  "migrations": [
    {
      "tag": "v1",
      "new_sqlite_classes": ["OnePasswordCliContainer"]
    }
  ],
  "containers": [
    {
      "image": "registry.cloudflare.com/xxxxxxxxxxxxxxxxxxxxxxx/onepassword-cli:1.0",
      "name": "1password-cli",
      "class_name": "OnePasswordCliContainer",
      "instance_type": "basic",
      "max_instances": 3
    }
  ],
  "kv_namespaces": [
    {
      "id": "xxxxxxxxxxxxxxxxxxxxxxx",
      "binding": "KV"
    }
  ],
  "version_metadata": {
    "binding": "CF_VERSION_METADATA"
  },
}

My Dockerfile looks like this and was successfully pushed up manually using wrangler containers push onepassword-cli:1.0 from a locally built image (which works great locally):

# syntax=docker/dockerfile:1

FROM docker.io/ghostwriternr/cloudflare-sandbox:0.0.5

# Install required packages
RUN apt-get update && apt-get install -y git curl jq

# Install 1Password CLI from official image
COPY --from=1password/op:2 /usr/local/bin/op /usr/local/bin/op

# Run
EXPOSE 3000
CMD ["bun", "index.ts"]

Happy to help provide/share anything else that may be needed to diagnose, just let me know. Thank you.

Please provide any relevant error logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    awaiting Cloudflare responseAwaiting response from workers-sdk maintainer teambugSomething that isn't workingcontainersinternalRequires support from the Cloudflare Platform

    Type

    Projects

    Status

    Untriaged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions