Two Scheduling Methods

Watchtower supports two mutually exclusive docker watchtower schedule methods:

  1. WATCHTOWER_POLL_INTERVAL — Simple recurring interval in seconds. Best for homelab or dev environments where exact timing doesn't matter.
  2. WATCHTOWER_SCHEDULE — Precise cron expression. Best for production where you want updates only at specific low-traffic times.
⚠️
You cannot set both WATCHTOWER_SCHEDULE and WATCHTOWER_POLL_INTERVAL simultaneously. If both are present, WATCHTOWER_SCHEDULE takes precedence and Watchtower will log a warning.

WATCHTOWER_POLL_INTERVAL — Simple Interval

Set the watchtower docker interval in seconds with WATCHTOWER_POLL_INTERVAL:

environment:
  - WATCHTOWER_POLL_INTERVAL=3600    # Every 1 hour
  # - WATCHTOWER_POLL_INTERVAL=21600  # Every 6 hours
  # - WATCHTOWER_POLL_INTERVAL=86400  # Every 24 hours (default)

The default is 86400 seconds (24 hours) if neither variable is set. The minimum recommended value is 300 seconds (5 minutes) to avoid rate limiting from Docker Hub.

WATCHTOWER_SCHEDULE — Cron Expression

The watchtower docker cron schedule format uses 6 fields. This is important — standard cron tools use 5 fields, but Watchtower requires 6 with seconds as the first field:

FieldValuesExample
Seconds0–590
Minutes0–5930
Hours0–234
Day of Month1–31 or **
Month1–12 or **
Day of Week0–6 (Sun=0) or **

WATCHTOWER_SCHEDULE Cron Examples

# Every day at 4:00 AM
- WATCHTOWER_SCHEDULE=0 0 4 * * *

# Every Sunday at 2:00 AM
- WATCHTOWER_SCHEDULE=0 0 2 * * 0

# Every 6 hours (midnight, 6am, noon, 6pm)
- WATCHTOWER_SCHEDULE=0 0 */6 * * *

# Every weekday (Mon-Fri) at 3:30 AM
- WATCHTOWER_SCHEDULE=0 30 3 * * 1-5

# Every hour at :15 minutes
- WATCHTOWER_SCHEDULE=0 15 * * * *

# First day of every month at 1 AM
- WATCHTOWER_SCHEDULE=0 0 1 1 * *

Watchtower Docker Run Once Mode

The watchtower docker run once flag tells Watchtower to check and update all containers exactly once, then exit. This is useful for CI/CD pipelines, testing, or scheduled external triggers:

# Via docker run --rm (container removes itself after one run)
docker run --rm \
  -v /var/run/docker.sock:/var/run/docker.sock \
  containrrr/watchtower --run-once

# Via environment variable
docker run -d \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -e WATCHTOWER_RUN_ONCE=true \
  containrrr/watchtower

Combined with an external cron job (system cron, CI scheduler, Kubernetes CronJob), this gives you full control over when updates run without Watchtower's built-in scheduler.

Watchtower Docker Run Now — HTTP API Trigger

Trigger an immediate watchtower docker run now update cycle using the HTTP API without restarting Watchtower:

# Enable the HTTP API (add to Watchtower environment)
- WATCHTOWER_HTTP_API_UPDATE=true
- WATCHTOWER_HTTP_API_TOKEN=mySecretToken

# Trigger update via curl
curl -H "Authorization: Bearer mySecretToken" \
  http://watchtower:8080/v1/update

The HTTP API runs Watchtower's update cycle immediately, on demand, while the normal schedule continues in the background.

Timezone Configuration

Cron expressions use the container's timezone, which defaults to UTC. To match your local time, mount the host timezone file:

services:
  watchtower:
    image: containrrr/watchtower
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - /etc/timezone:/etc/timezone:ro      # Mount host timezone
      - /etc/localtime:/etc/localtime:ro    # Mount localtime
    environment:
      - WATCHTOWER_SCHEDULE=0 0 4 * * *    # Now runs at 4 AM in host's timezone

Frequently Asked Questions

Why is my watchtower docker schedule not running at the right time?

Most likely a timezone mismatch. The container runs in UTC by default. Mount /etc/timezone:/etc/timezone:ro and /etc/localtime:/etc/localtime:ro from the host, then adjust your cron expression accordingly. Also verify you're using 6-field cron format (with seconds as the first field).

What is the minimum watchtower docker interval?

Technically 1 second, but practically the minimum should be 300 seconds (5 minutes). Docker Hub rate-limits anonymous pulls to 100 pulls per 6 hours per IP. Authenticated users get 200 pulls/hour. Setting an interval below 5 minutes with many containers will quickly hit these limits.

Can I trigger watchtower to run immediately without restarting it?

Yes, via the HTTP API. Set WATCHTOWER_HTTP_API_UPDATE=true and WATCHTOWER_HTTP_API_TOKEN when starting Watchtower, then send a POST request to http://watchtower:8080/v1/update with the Bearer token. This triggers one full update cycle immediately.

AC
Alex Chen
Docker Infrastructure Engineer
Alex has configured Watchtower scheduling across environments ranging from single-host homelabs to 200-node Docker Swarm clusters. All cron examples are validated against containrrr/watchtower v1.7.x.