Resource Configuration

Resource configuration allows you to control CPU, memory limits, and volume mounts for your application processes. These settings can be configured globally (defaults) or per process.

Overview

  • Set default resource limits that apply to all processes
  • Configure process-specific overrides for different workloads
  • Mount host directories into your containers
  • Changes take effect on next deployment

Resource Limits

CPU Limits

CPU limits control how much CPU capacity a process can use:

  • Specified as a decimal number representing CPU cores
  • Examples:
    • 0.5 = 50% of one CPU core
    • 1.0 = One full CPU core
    • 2.0 = Two full CPU cores

Memory Limits

Memory limits control the maximum memory a process can use:

  • Specified using units: M (megabytes) or G (gigabytes)
  • Examples:
    • 512M = 512 megabytes
    • 1G = 1 gigabyte
    • 2.5G = 2.5 gigabytes

Volume Mounts

Volumes allow you to mount host directories into your containers:

  • source: Path on the host machine
  • target: Path inside the container
  • read_only: Optional flag to make the mount read-only

Volume Mount Examples

  • Persistent storage: /data/uploads:/app/uploads
  • Configuration files: /etc/configs:/etc/app:ro
  • Shared assets: /shared/assets:/app/public

Configuration Inheritance

  1. Default settings apply to all processes
  2. Process-specific settings override defaults
  3. Settings not specified in process config use defaults