1.2 KiB
1.2 KiB
Implementation Plan: DefectDojo Upload
Objective
Implement a task that pushes all SARIF/JSON reports from the PVC to DefectDojo via its API.
Requirements
- Define a task template named
upload-defectdojo. - Depend on the completion of all parallel scanner tasks (Phase 2).
- Mount the shared PVC at
/workspace. - Expect DefectDojo API keys and URL to be injected as environment variables via Infisical (with initContainer wait logic).
- Iterate over the
/workspace/reports/directory. - For each file, make an API request to DefectDojo to import the scan results (mapping the file type to the correct DefectDojo parser, e.g., SARIF -> Generic SARIF).
Agent Instructions
- Add the
upload-defectdojotemplate to theClusterWorkflowTemplate. - Write the API upload script (Python, curl, or a dedicated CLI) in the task template.
- Configure the Infisical initContainer to wait for the DefectDojo credentials.
- CRITICAL: File Splitting: Do NOT put everything into one giant file! Split your YAML manifests or configurations into separate, smaller files (e.g. using separate Helm template files, configmaps, or helper scripts) to prevent exhausting the context window.