gcip2.pipeline_core¶
Classes
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Defines default variables for all jobs. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Similar to image property, but will link the specified services to the image container. |
|
|
|
Trigger allows you to define downstream pipeline trigger. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
Create a new model by parsing and validating input data from keyword arguments. |
|
|
|
|
|
Create a new model by parsing and validating input data from keyword arguments. |
|
- class gcip2.pipeline_core.Trigger(*, project=None, ref=None, file=None, branch=None, strategy=None, include=None, forward=None, component=None, remote=None, inputs=None, **extra_data)[source]¶
Bases:
BaseModelTrigger allows you to define downstream pipeline trigger.
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
project (str | None)
ref (str | None)
file (str | None)
branch (str | None)
strategy (TriggerStrategy | None)
include (list[TriggerIncludeArtifact | TriggerIncludeLocal | TriggerIncludeTemplate] | None)
forward (TriggerForward | None)
component (str | None)
remote (str | None)
inputs (Any | None)
extra_data (Any)
- strategy: TriggerStrategy | None¶
depend or mirror
- Type:
You can mirror or depend on the pipeline status from the triggered pipeline to the source bridge job by using strategy
- class gcip2.pipeline_core.Pipeline(**extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- stages: list[Stage | str] | None¶
Groups jobs into stages. All jobs in one stage must complete before next stage is executed.
- include: list[IncludeComponent]¶
- variables: dict[str, GlobalVariables] | None¶
- class gcip2.pipeline_core.Job(*, image=None, services=None, before_script=None, after_script=None, hooks=None, rules=None, variables=None, cache=None, id_tokens=None, identity=None, inputs=None, secrets=None, script=None, run=None, stage=None, only=None, extends=None, needs=None, except_=None, tags=<factory>, allow_failure=None, timeout=None, when=None, start_in=None, manual_confirmation=None, dependencies=None, artifacts=<factory>, environment=None, release=None, coverage=None, retry=None, parallel=None, interruptible=None, resource_group=None, trigger=None, inherit=None, publish=None, pages=None, name='', **extra_data)[source]¶
Bases:
JobTemplateCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
image (Image | None)
hooks (Any | None)
rules (list[JobRule] | None)
variables (dict[str, JobVariables | str] | None)
cache (Any | None)
id_tokens (IdTokens | None)
identity (Identity | None)
inputs (BaseInput | None)
secrets (Any | None)
run (Any | None)
only (Any | None)
except_ (Any | None)
timeout (str | None)
when (JobWhen | None)
start_in (str | None)
manual_confirmation (str | None)
artifacts (Artifacts)
environment (Any | None)
release (Any | None)
coverage (str | None)
retry (Any | None)
parallel (Parallel | int | None)
interruptible (bool | None)
resource_group (str | None)
trigger (Trigger | None)
inherit (Any | None)
publish (str | None)
pages (Any | None)
name (str)
extra_data (Any)
- class gcip2.pipeline_core.Stage(*values)[source]¶
-
- PRE = '.pre'¶
- POST = '.post'¶
- JOBS = 'jobs'¶
- BUILD = 'build'¶
- TEST = 'test'¶
- DEPLOY = 'deploy'¶
- class gcip2.pipeline_core.Image(*, name=None, entrypoint=<factory>, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- class gcip2.pipeline_core.Needs(*, pipeline=None, job=None, project=None, optional=None, artifacts=None, parallel=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- class gcip2.pipeline_core.Artifacts(*, paths=None, exclude=None, expose_as=None, expire_in=None, name=None, public=None, access=None, reports=None, untracked=None, when=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- exclude: list[str] | None¶
A list of paths to files/folders that should be excluded in the artifact.
- expose_as: str | None¶
Can be used to expose job artifacts in the merge request UI. GitLab will add a link <expose_as> to the relevant merge request that points to the artifact.
- expire_in: str | None¶
Use expire_in to specify how long job artifacts are stored before they expire and are deleted.
- name: str | None¶
name keyword to define the name of the created artifacts archive. You can specify a unique name for every archive.
- Type:
Use the artifacts
- public: bool | None¶
public to determine whether the job artifacts should be publicly available.
- Type:
Use artifacts
- access: ArtifactsAccess | None¶
access to determine who can access the job artifacts from the GitLab UI or API.
- Type:
Use artifacts
- reports: ArtifactsReports | None¶
- class gcip2.pipeline_core.ArtifactsReports(*, accessibility=None, annotations=None, api_fuzzing=None, browser_performance=None, coverage_report=None, codequality=None, container_scanning=None, coverage_fuzzing=None, cyclonedx=None, dast=None, dependency_scanning=None, dotenv=None, junit=None, load_performance=None, metrics=None, requirements=None, sarif=None, sast=None, secret_detection=None, terraform=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
coverage_report (ArtifactsReportsCoverage | None)
extra_data (Any)
- accessibility: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsaccessibility
- Type:
https
- annotations: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsannotations
- Type:
https
- api_fuzzing: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsapi_fuzzing
- Type:
https
- browser_performance: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsbrowser_performance
- Type:
https
- coverage_report: ArtifactsReportsCoverage | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportscoverage_report
- Type:
https
- codequality: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportscodequality
- Type:
https
- container_scanning: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportscontainer_scanning
- Type:
https
- coverage_fuzzing: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportscoverage_fuzzing
- Type:
https
- cyclonedx: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportscyclonedx
- Type:
https
- dast: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsdast
- Type:
https
- dependency_scanning: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsdependency_scanning
- Type:
https
- dotenv: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsdotenv
- Type:
https
- junit: str | list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsjunit
- Type:
https
- load_performance: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsload_performance
- Type:
https
- metrics: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsmetrics
- Type:
https
- requirements: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportsrequirements
- Type:
https
- sarif: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportssarif
- Type:
https
- sast: list[str] | None¶
//docs.gitlab.com/ci/yaml/artifacts_reports/#artifactsreportssast
- Type:
https
- class gcip2.pipeline_core.IncludeComponent(*, inputs=None, rules=None, component=None, **extra_data)[source]¶
Bases:
IncludeItemCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- class gcip2.pipeline_core.BaseInput(*, type=BaseInputType.STRING, description=None, options=None, regex=None, default=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- class gcip2.pipeline_core.Workflow(*, name=None, auto_cancel=None, rules=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
name (str | None)
auto_cancel (WorkflowAutoCancel | None)
rules (list[WorkflowRule] | None)
extra_data (Any)
- auto_cancel: WorkflowAutoCancel | None¶
Define the rules for when pipeline should be automatically cancelled.
- class gcip2.pipeline_core.WorkflowAutoCancel(*, on_job_failure=None, on_new_commit=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
on_job_failure (WorkflowAutoCancelOnJobFailure | None)
on_new_commit (WorkflowAutoCancelOnNewCommit | None)
extra_data (Any)
- on_job_failure: WorkflowAutoCancelOnJobFailure | None¶
Define which jobs to stop after a job fails.
- on_new_commit: WorkflowAutoCancelOnNewCommit | None¶
Configure the behavior of the auto-cancel redundant pipelines feature.
- class gcip2.pipeline_core.Rule(*, if_=None, changes=None, exists=None, variables=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- if_: str | None¶
Expression to evaluate whether additional attributes should be provided to the job.
- changes: RuleChanges | list[str] | None¶
Additional attributes will be provided to job if any of the provided paths matches a modified file.
- class gcip2.pipeline_core.WorkflowAutoCancelOnJobFailure(*values)[source]¶
-
- NONE = 'none'¶
- ALL = 'all'¶
- class gcip2.pipeline_core.RuleChanges(*, paths=<factory>, compare_to=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- class gcip2.pipeline_core.WorkflowAutoCancelOnNewCommit(*values)[source]¶
-
- NONE = 'none'¶
- CONSERVATIVE = 'conservative'¶
- INTERRUPTIBLE = 'interruptible'¶
- class gcip2.pipeline_core.JobVariables(*, value=None, expand=None, **extra_data)[source]¶
Bases:
BaseModelDefines default variables for all jobs. Job level property overrides global variables.
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- class gcip2.pipeline_core.GlobalVariables(*, value=None, expand=None, description=None, options=<factory>, **extra_data)[source]¶
Bases:
JobVariablesCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- class gcip2.pipeline_core.Default(*, after_script=None, artifacts=None, before_script=None, hooks=None, cache=None, image=None, interruptible=None, id_tokens=None, identity=None, retry=None, services=None, tags=None, timeout=None, **extra_data)[source]¶
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- interruptible: bool | None¶
Interruptible is used to indicate that a job should be canceled if made redundant by a newer pipeline run.