DrydockDrydock
ConfigurationLogs

Logs

Configure drydock log output and use the built-in log viewers to monitor application and container activity.

Server Log Configuration

Control drydock's own log output with environment variables.

Variables

Env varRequiredDescriptionSupported valuesDefault in official Docker image
DD_LOG_LEVELLog levelfatal, error, warn, info, debug, traceinfo
DD_LOG_FORMATLog formattext jsontext
DD_LOG_BUFFER_ENABLEDEnable in-memory log ring buffer used by UI/API log viewertrue, falsetrue

The official image sets DD_LOG_FORMAT=text by default for pretty, human-readable logs. Set DD_LOG_FORMAT=json when you want structured output for log aggregators. Set DD_LOG_BUFFER_ENABLED=false to disable the in-memory ring buffer (reduces per-log processing overhead).

Examples

Set debug level

services:
  drydock:
    image: codeswhat/drydock
    ...
    environment:
      - DD_LOG_LEVEL=debug
docker run -e DD_LOG_LEVEL=debug ... codeswhat/drydock

Set json format (for ElasticSearch ingestion for example)

docker run -e DD_LOG_FORMAT=json ... codeswhat/drydock
services:
  drydock:
    image: codeswhat/drydock
    ...
    environment:
      - DD_LOG_FORMAT=json

Application Log Viewer

The Configuration > Logs page provides a terminal-style viewer for drydock's own runtime logs — startup events, polling cycles, registry checks, trigger executions, and errors.

By default, this view opens a live WebSocket stream to WS /api/v1/log/stream and backfills the selected tail size on connect.

When enabled, logs are stored in an in-memory ring buffer (last 1,000 entries) and are not persisted to disk.
If DD_LOG_BUFFER_ENABLED=false, buffered-entry API responses are empty.

Toolbar controls

ControlDescription
LiveToggle real-time WebSocket streaming on/off. Shows Live, Offline, or Paused status.
LevelFilter by log level: all, debug, info, warn, error.
TailBackfill size on connect/filter apply: 50, 100, 500, or 1,000 entries.
Component filterSubstring filter for component name (for example api, watcher).
ApplyReapply filters. In live mode this reconnects the stream with the new query.
ResetReset filters to defaults (all, tail=100, empty component).

When Live is disabled, the view falls back to one-shot API fetches from GET /api/v1/log/entries using the same filters.

Scroll behavior

The log viewport is pinned to the newest entries by default. If you scroll up, it automatically unpins so your reading position is preserved. Use Pin / Unpin to control this behavior explicitly.

Container Log Viewer

The container log viewer provides real-time log streaming via WebSocket — logs appear instantly as the container produces them, with no polling delay. The viewer is available in two modes:

  • Full-page viewer at /containers/:id/logs, with a header showing the container name, image, and status.
  • Compact mode inside the slide-in container detail panel.

A maximum of 5,000 lines are retained in the viewport buffer. Older lines are discarded as new ones arrive.

Toolbar controls

ControlDescription
Pause / ResumePause the live WebSocket stream; resume reconnects and continues streaming.
Unpin / PinToggle auto-scroll to newest entries.
CopyCopy all visible log lines to clipboard.
DownloadDownload container logs as a .log text file (gzip-compressed if the browser supports it).
SearchFree-text search across visible log entries.
. Regex*Toggle regex mode for the search field.
stdoutShow or hide the stdout stream.
stderrShow or hide the stderr stream.
TailNumber of initial historical lines to load when the viewer opens: 100, 500, 1,000, or All.
LevelFilter by log level. Only shown when the container emits JSON-structured logs (see below).
Prev / NextNavigate between search matches. Only shown when a search is active, with a match counter.

ANSI color rendering

Terminal ANSI color codes are rendered correctly in the viewer — colored build output, test runners, and CLI tools display as they would in a real terminal.

JSON log detection

When the viewer detects JSON-structured log lines, it automatically pretty-prints them with syntax highlighting. Keys, strings, numbers, booleans, and null are each distinctly colored for readability.

JSON-structured logs also enable the Level filter in the toolbar. The viewer auto-detects the level field from common conventions: level, severity, logLevel, log_level, and lvl.

Stream filtering

Each log line is tagged with a color-coded stdout or stderr badge. Use the stream toggle buttons in the toolbar to show or hide either stream independently.

Scroll behavior

Auto-scroll follows new entries by default. Scrolling up automatically pauses auto-scroll so your reading position is preserved. Click Pin to jump back to the bottom and re-enable auto-scroll.

Agent containers

Container log streaming is available for local containers. For agent-managed containers, HTTP-based log download is available.

Agent Log Viewer

Agent runtime logs are available from the Agents page. Open an agent's detail slide-in panel and switch to the Logs tab.

On this page