CI/CD build pipeline database schema

How a build system models its data: versioned pipeline definitions, immutable runs triggered by a commit, stages with approval gates, a job DAG stored as edges, runners and capabilities, attempts and retries, artifacts, caches and streamed logs.

CI CD Pipeline ER diagram

CI/CD build pipeline database schema n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 n1 projects idBIGINT slugVARCHAR display_nameVARCHAR repository_urlVARCHAR default_branchVARCHAR concurrency_limitINTEGER artifact_retentio…INTEGER is_activeBOOLEAN created_atTIMESTAMP pipeline_definitions idBIGINT project_idBIGINT nameVARCHAR versionINTEGER config_sourceVARCHAR config_shaCHAR config_bodyTEXT is_currentBOOLEAN created_atTIMESTAMP pipeline_runs idBIGINT project_idBIGINT pipeline_definiti…BIGINT rerun_of_run_idBIGINT run_numberINTEGER trigger_typeVARCHAR triggered_byVARCHAR commit_shaCHAR commit_messageVARCHAR ref_nameVARCHAR statusVARCHAR conclusionVARCHAR queued_atTIMESTAMP started_atTIMESTAMP finished_atTIMESTAMP run_stages idBIGINT run_idBIGINT nameVARCHAR positionINTEGER requires_approvalBOOLEAN approved_byVARCHAR approved_atTIMESTAMP statusVARCHAR jobs idBIGINT run_idBIGINT stage_idBIGINT nameVARCHAR required_labelsVARCHAR allow_failureBOOLEAN timeout_secondsINTEGER max_attemptsINTEGER statusVARCHAR conclusionVARCHAR job_dependencies job_idBIGINT depends_on_job_idBIGINT conditionVARCHAR runners idBIGINT nameVARCHAR scopeVARCHAR project_idBIGINT statusVARCHAR max_concurrent_jo…INTEGER last_heartbeat_atTIMESTAMP registered_atTIMESTAMP runner_capabilities runner_idBIGINT capability_keyVARCHAR capability_valueVARCHAR job_attempts idBIGINT job_idBIGINT runner_idBIGINT attempt_numberINTEGER statusVARCHAR conclusionVARCHAR exit_codeINTEGER queued_atTIMESTAMP started_atTIMESTAMP finished_atTIMESTAMP artifacts idBIGINT job_attempt_idBIGINT nameVARCHAR storage_keyVARCHAR size_bytesBIGINT content_sha256CHAR expires_atTIMESTAMP created_atTIMESTAMP cache_entries idBIGINT project_idBIGINT created_by_attemp…BIGINT cache_keyVARCHAR key_prefixVARCHAR scope_refVARCHAR storage_keyVARCHAR size_bytesBIGINT last_used_atTIMESTAMP created_atTIMESTAMP job_log_chunks idBIGINT job_attempt_idBIGINT sequenceINTEGER byte_offsetBIGINT contentTEXT is_finalBOOLEAN created_atTIMESTAMP

Related database schemas