version: 1
kind: HwlabHwpodNodeDeploymentConfig
metadata:
  name: hwlab-hwpod-nodes
  owner: unidesk
  spec: PJ2026-010104
  implementationRef: draft-2026-07-16-python-hwpod-node-public-origin

cloud:
  controlNode: NC01
  lane: v03
  kubeRoute: NC01:k3s
  namespace: hwlab-v03
  publicOrigin: https://lab-dev-hwpod.hwpod.com
  nodeOpsUrl: https://lab-dev-hwpod.hwpod.com/v1/hwpod-node-ops
  nodeAuth:
    sourceRef: hwlab/nc01-v03-hwpod-node.env
    sourceKey: HWLAB_HWPOD_NODE_WS_TOKEN
    generateIfMissing: true
    secretName: hwlab-v03-hwpod-node-auth
    targetKey: token
  opsAuth:
    sourceRef: hwlab/nc01-v03-admin.env
    sourceKey: HWLAB_API_KEY

targets:
  D601-WIN:
    enabled: true
    lane: v03
    providerId: D601-WIN
    windowsRoute: D601-WIN:win/f/Work/ConStart
    nodeId: node-d601-f103-v2
    hwpodId: constart-71freq-c
    interactiveUser: liang
    python:
      probeLauncherPath: "C:\\Windows\\py.exe"
      guiLauncherPath: "C:\\Windows\\pyw.exe"
      launcherArgs: []
      expectedVersionPrefix: "3.13.14"
    runtime:
      root: "C:\\Users\\liang\\hwlab-node"
      scriptPath: "C:\\Users\\liang\\hwlab-node\\hwlab-node.py"
      configPath: "C:\\Users\\liang\\.hwlab\\config.json"
      credentialPath: "C:\\Users\\liang\\.hwlab\\hwpod-node.token"
      logPath: "C:\\Users\\liang\\.hwlab\\logs\\hwlab-node.log"
      applyTimeoutMs: 90000
    artifact:
      metadataUrl: https://lab-dev.hwpod.com/v1/hwlab-node/update
      channel: stable
      platform: windows
      localPath: /root/hwlab-v03/tools/hwlab-node.py
      localVersion: 0.1.3
    workspace:
      allowedRoots:
        - "F:\\Work\\ConStart"
      defaultRoot: "F:\\Work\\ConStart"
    desktopConfig:
      serverUrl: https://lab-dev-hwpod.hwpod.com/hwpods/devices
      autoConnect: true
      requireCredential: true
      updateEnabled: true
      updateAutoApplyWhenIdle: false
    startup:
      mode: hkcu-run
      runKeyName: hwlab-node-d601-win
      initialLaunch: interactive-process
      processPattern: hwlab-node.py
      legacyTaskNames:
        - HWLAB-HWPOD-Node-WS
        - hwpod-node-ws-periodic
      legacyRunKeyNames:
        - hwpod-node-ws
      legacyProcessPatterns:
        - tools\hwpod-node.ts connect
        - run-node-ws-detached.cmd
    projectManagementSourceRef: config/hwlab-project-management/constart-71freq-mdtodo.yaml#projectManagement.sources[0]

  G14-WSL:
    enabled: true
    lane: v03
    providerId: G14-WSL
    windowsRoute: G14-WSL:win
    nodeId: node-g14-wsl-constar
    hwpodId: constar-workspace
    interactiveUser: lyon
    python:
      probeLauncherPath: "C:\\Windows\\py.exe"
      guiLauncherPath: "C:\\Windows\\pyw.exe"
      launcherArgs:
        - "-3.11"
      expectedVersionPrefix: "3.11.9"
    runtime:
      root: "C:\\Users\\lyon\\hwlab-node"
      scriptPath: "C:\\Users\\lyon\\hwlab-node\\hwlab-node.py"
      configPath: "C:\\Users\\lyon\\.hwlab\\config.json"
      credentialPath: "C:\\Users\\lyon\\.hwlab\\hwpod-node.token"
      logPath: "C:\\Users\\lyon\\.hwlab\\logs\\hwlab-node.log"
      applyTimeoutMs: 90000
    artifact:
      metadataUrl: https://lab-dev.hwpod.com/v1/hwlab-node/update
      channel: stable
      platform: windows
    workspace:
      allowedRoots:
        - "D:\\Work\\CONSTAR_workspace"
      defaultRoot: "D:\\Work\\CONSTAR_workspace"
    desktopConfig:
      serverUrl: https://lab-dev.hwpod.com
      autoConnect: true
      requireCredential: true
      updateEnabled: true
      updateAutoApplyWhenIdle: false
    startup:
      mode: hkcu-run
      runKeyName: hwlab-node-g14-wsl
      initialLaunch: interactive-process
      processPattern: hwlab-node.py
    projectManagementSourceRef: config/hwlab-project-management/constar-workspace-mdtodo.yaml#projectManagement.sources[0]
