Configuration Guide

Comprehensive guide to configuring Woodpecker for optimal performance

Server Configuration

Configure the Woodpecker server for optimal performance and resource usage

server:
  address: "0.0.0.0:8080"  # Server listening address
  max_connections: 1000    # Maximum number of client connections
  max_workers: 16         # Maximum number of worker threads
  max_queue_size: 10000   # Maximum size of the request queue
  timeout: 30s            # Request timeout duration
Parameter Description Default
server.address Server listening address and port 0.0.0.0:8080
server.max_connections Maximum number of concurrent client connections 1000
server.max_workers Number of worker threads for request processing 16
server.max_queue_size Maximum size of the request processing queue 10000
server.timeout Request timeout duration 30s

Storage Configuration

Configure storage backends and optimize data persistence

storage:
  type: "minio"           # Storage type (minio, local)
  minio:
    endpoint: "localhost:9000"
    access_key: "minioadmin"
    secret_key: "minioadmin"
    bucket: "woodpecker"
    use_ssl: false
  local:
    base_dir: "/data/woodpecker"
    max_file_size: "1GB"
    max_fragment_size: "128MB"
Parameter Description Default
storage.type Storage backend type (minio, local) minio
storage.minio.endpoint MinIO server endpoint localhost:9000
storage.minio.bucket MinIO bucket name woodpecker
storage.local.base_dir Base directory for local storage /data/woodpecker
storage.local.max_file_size Maximum size of a single log file 1GB
storage.local.max_fragment_size Maximum size of a single fragment 128MB

Cache Configuration

Optimize memory usage and caching behavior

cache:
  max_memory: "1GB"       # Maximum memory usage for cache
  max_entries: 10000     # Maximum number of cache entries
  max_bytes: "100MB"     # Maximum size of a single cache entry
  max_interval: 1000     # Cache cleanup interval in milliseconds
  eviction_policy: "LRU" # Cache eviction policy (LRU, FIFO)
Parameter Description Default
cache.max_memory Maximum memory usage for cache 1GB
cache.max_entries Maximum number of cache entries 10000
cache.max_bytes Maximum size of a single cache entry 100MB
cache.max_interval Cache cleanup interval in milliseconds 1000
cache.eviction_policy Cache eviction policy (LRU, FIFO) LRU

Log Configuration

Configure log behavior and performance parameters

log:
  max_segments: 100      # Maximum number of segments per log
  max_segment_size: "1GB" # Maximum size of a single segment
  max_entries: 1000000  # Maximum number of entries per segment
  flush_interval: 1000  # Flush interval in milliseconds
  sync_interval: 5000   # Sync interval in milliseconds
Parameter Description Default
log.max_segments Maximum number of segments per log 100
log.max_segment_size Maximum size of a single segment 1GB
log.max_entries Maximum number of entries per segment 1000000
log.flush_interval Flush interval in milliseconds 1000
log.sync_interval Sync interval in milliseconds 5000

Monitoring Configuration

Configure monitoring and metrics collection

monitoring:
  enabled: true          # Enable monitoring
  prometheus:
    enabled: true       # Enable Prometheus metrics
    port: 9090         # Prometheus metrics port
  logging:
    level: "info"      # Log level (debug, info, warn, error)
    format: "json"     # Log format (text, json)
Parameter Description Default
monitoring.enabled Enable monitoring features true
monitoring.prometheus.enabled Enable Prometheus metrics true
monitoring.prometheus.port Prometheus metrics port 9090
monitoring.logging.level Log level (debug, info, warn, error) info
monitoring.logging.format Log format (text, json) json