Skip to content

fix: pin Watchtower DOCKER_API_VERSION for Docker Engine 28+ - #10

Closed
taobojlen wants to merge 1 commit into
mainfrom
fix/watchtower-docker-api-version
Closed

fix: pin Watchtower DOCKER_API_VERSION for Docker Engine 28+#10
taobojlen wants to merge 1 commit into
mainfrom
fix/watchtower-docker-api-version

Conversation

@taobojlen

@taobojlen taobojlen commented Jul 24, 2026

Copy link
Copy Markdown
Member

Watchtower 1.7.1's Docker SDK defaults to Docker API version 1.25, which is too old for Docker Engine 28+. On modern hosts the override fails to talk to dockerd.

Pins the API version explicitly via DOCKER_API_VERSION=1.44 in the watchtower service environment: list so the SDK negotiates a supported API version.

One-line change to docker-compose.override.example.yaml; nothing else touched.

Review in cubic

Watchtower 1.7.1's Docker SDK defaults to Docker API version 1.25, which
is too old for Docker Engine 28+. On modern hosts the override fails to
talk to dockerd. Pin the API version explicitly via DOCKER_API_VERSION=1.44.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 1 file

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="docker-compose.override.example.yaml">

<violation number="1" location="docker-compose.override.example.yaml:25">
P2: This override's comment misidentifies the affected daemon version, and the unconditional pin introduces a compatibility regression for Docker Engine 24 and older because those daemons reject client API 1.44 as too new. Correct the version rationale and either preserve negotiation or document/enforce a Docker Engine 25+ prerequisite for this example.</violation>
</file>

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

- WATCHTOWER_LABEL_ENABLE=true # ONLY update opted-in containers — never db
- WATCHTOWER_POLL_INTERVAL=300 # poll GHCR every 5 min
- WATCHTOWER_CLEANUP=true # delete old images after updating
- DOCKER_API_VERSION=1.44 # watchtower 1.7.1's SDK defaults to 1.25, too old for Docker Engine 28+

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: This override's comment misidentifies the affected daemon version, and the unconditional pin introduces a compatibility regression for Docker Engine 24 and older because those daemons reject client API 1.44 as too new. Correct the version rationale and either preserve negotiation or document/enforce a Docker Engine 25+ prerequisite for this example.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At docker-compose.override.example.yaml, line 25:

<comment>This override's comment misidentifies the affected daemon version, and the unconditional pin introduces a compatibility regression for Docker Engine 24 and older because those daemons reject client API 1.44 as too new. Correct the version rationale and either preserve negotiation or document/enforce a Docker Engine 25+ prerequisite for this example.</comment>

<file context>
@@ -22,3 +22,4 @@ services:
       - WATCHTOWER_LABEL_ENABLE=true   # ONLY update opted-in containers — never db
       - WATCHTOWER_POLL_INTERVAL=300   # poll GHCR every 5 min
       - WATCHTOWER_CLEANUP=true        # delete old images after updating
+      - DOCKER_API_VERSION=1.44        # watchtower 1.7.1's SDK defaults to 1.25, too old for Docker Engine 28+
</file context>

@taobojlen taobojlen closed this Jul 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant