# System Configuration Defaults
#
# Default values for system configuration
# Migrated from provisioning/kcl/system_config.k

let contracts = import "contracts.ncl" in

{
  default_system = {
    version = "1.0.0",
    install_path = "/opt/provisioning",
    os_name = 'linux,
    os_version = "5.15.0",
    config_base_path = "/etc/provisioning",
    cache_base_path = "/var/cache/provisioning",
    workspaces_dir = "/opt/workspaces",
    system_architecture = "x86_64",
    cpu_count = 8,
    memory_total_gb = 32,
    disk_total_gb = 500,
    setup_date = "2025-12-15T00:00:00Z",
    setup_by_user = "provisioning",
    setup_hostname = "provisioning-host",
  } | contracts.SystemConfig,

  default_orchestrator = {
    enabled = true,
    endpoint = "http://localhost:9090",
    port = 9090,
    timeout_seconds = 30,
    health_check_interval_seconds = 5,
  } | contracts.OrchestratorConfig,

  default_control_center = {
    enabled = true,
    url = "http://localhost:3000",
    port = 3000,
    timeout_seconds = 30,
    database = {
      backend = 'memory,
    },
  } | contracts.ControlCenterConfig,

  default_kms = {
    enabled = true,
    backend = 'age,
    rotation_days = 90,
  } | contracts.KMSConfig,

  default_platform_services = {
    orchestrator = {
      enabled = true,
      endpoint = "http://localhost:9090",
      port = 9090,
      timeout_seconds = 30,
      health_check_interval_seconds = 5,
    },
    control_center = {
      enabled = true,
      url = "http://localhost:3000",
      port = 3000,
      timeout_seconds = 30,
      database = { backend = 'memory },
    },
    kms_service = {
      enabled = true,
      backend = 'age,
      rotation_days = 90,
    },
  } | contracts.PlatformServicesConfig,

  default_user_prefs = {
    preferred_editor = 'vim,
    preferred_output_format = 'text,
    auto_confirm_operations = false,
    log_level = 'info,
    default_timeout_seconds = 300,
  } | contracts.UserPreferences,
}
