(workflowData *WorkflowData, sandboxEnabled bool)
| 285 | } |
| 286 | |
| 287 | func (e *CopilotEngine) resolveCopilotCommand(workflowData *WorkflowData, sandboxEnabled bool) (string, string) { |
| 288 | if workflowData.EngineConfig != nil && workflowData.EngineConfig.Command != "" { |
| 289 | copilotExecLog.Printf("Using serialized custom command script: %s", customEngineCommandScriptPath) |
| 290 | return customEngineCommandScriptPath, buildEngineCommandScriptSetup(workflowData.EngineConfig.Command) |
| 291 | } |
| 292 | if sandboxEnabled { |
| 293 | if isArcDindTopology(workflowData) { |
| 294 | return constants.GhAwRootDirShell + "/bin/copilot", "" |
| 295 | } |
| 296 | // AWF - use the installed binary directly |
| 297 | // The binary is mounted into the AWF container from /usr/local/bin/copilot |
| 298 | return constants.CopilotBinaryPath, "" |
| 299 | } |
| 300 | // Non-sandbox mode: use standard copilot command |
| 301 | return "copilot", "" |
| 302 | } |
| 303 | |
| 304 | func (e *CopilotEngine) buildCopilotExecPrefix(workflowData *WorkflowData, commandName string) string { |
| 305 | // Build the command - model is always passed via COPILOT_MODEL env var (see env block below). |
no test coverage detected