Command Builder#

Apptainer command construction and input manifest generation.

Command builder for direct Apptainer execution.

Replaces CWL generation. Builds the full apptainer exec command string and the input manifest for container consumption.

class ccat_workflow_manager.execution.command_builder.CommandBuilder[source]#

Bases: object

Builds Apptainer execution commands and input manifests.

build_command(step, run, version, software, config, input_files: List[str], input_products: List[dict], is_final_step: bool) str[source]#

Build the full apptainer exec command string.

Parameters:
  • step – ReductionStep model instance

  • run – ExecutedReductionStep model instance

  • version – ReductionSoftwareVersion model instance

  • software – ReductionSoftware model instance

  • config – ReductionStepConfig model instance

  • input_files – List of staged input file paths

  • input_products – List of upstream intermediate product dicts

  • is_final_step – Whether this is the final step in the pipeline

build_manifest(run, step, input_files: List[str], input_products: List[dict], config) dict[source]#

Build the manifest.json structure for the container.

The manifest is written to /workflow/config/manifest.json and provides the container with all context about its execution.