Manage a pipeline
Summary:
Function Name | Method | Return Type | Description |
---|---|---|---|
get_pipeline | get_pipeline (pipeline_name) | dict | Get information about a pipeline. |
list_pipelines | list_pipelines() | list of dict | Get a list of available pipelines. |
delete_pipeline | delete_pipeline (pipeline_name) | dict[str, str] | Delete one pipeline. |
❓ For pipeline update and deletion, you need the name (the name you provide when creating the pipeline) of the pipeline you want to update/delete. You can find it with function list_pipelines() (see the previous part).
Find and get information about pipelines
To get information about a pipeline, we need its name in the environment. You can search its name in the list of pipeline name of the environment.
Get list of pipelines
Function definition
To get all pipelines available in the current environment, you can get a list of pipeline name with this function:
Returns
List of pipelines represented as dict with the following keys:
pipeline_name
(str): Name of the pipeline.status
(str): eitherPending
orReady
.created_at
(str): The creation date in ISO format.updated_at
(str): The last update date in ISO format.repository_branch
(str): The branch of the repository where the pipeline was built.repository_url
(str): The url of the repository where the pipeline was built.commit_id
(str): The commit id on which the pipeline was built.origin
(str): The origin of the pipeline, can begit_repository
orlocal
.
Get information about one pipeline
Function definition
Get all information (repository, dependency, …) about one pipeline in the current environment with its name.
Parameters
pipeline_name
(str) – The name of the pipeline to get.
Returns
dict
: None if the pipeline does not exist; otherwise
the pipeline information, with the following keys:
parameters
(dict): Information used to create the pipeline with the following keys:pipeline_name
(str): Name of the pipeline.created_at
(str): Pipeline date of creation.created_by
(str): ID of the user who created the deployment.last_execution_id
(str): ID of the last execution of the pipeline.inputs
(list of dict): List of inputs represented as a dict with the following keys:input_name
(str): Input name.data_type
(str): Input data type.description
(str): Description of the open input.is_required
(bool): Whether the input is required.default_value
(str): Input default value.
outputs
(list of dict): List of outputs represented as a dict with the following keys:output_name
(str): Output name.step_name
(str): Name of the step that provides the open output.data_type
(str): Output data type.description
(str): Output description.
container_config
(dict[str, str]): Some pipeline configuration, with the following optional keys:language
(str): Language and version used for the pipeline.repository_url
(str): Remote repository url.repository_branch
(str): Branch name.included_folders
(list[str]): List of folders and files in the repository required for the pipeline execution.system_dependencies
(list[str]): List of system dependencies.dockerfile_path
(str): Path to the Dockerfile.requirements_path
(str): Path to the requirements.txt file.
creation_info
(dict): Information about the pipeline creation:commit_id
(str): The commit id on which the pipeline was built.status
(str): Either "Pending" or "Ready".origin
(str): The origin of the pipeline, can begit_repository
orlocal
.
Delete pipelines
Delete pipelines function
Function definition
Delete pipeline in the environment with his name.
Parameters
pipeline_name
(str) – Name of the pipeline to delete as defined in the create pipeline function.force_dependents_deletion
(bool, optional) – if True the associated endpoints will be deleted too. Defaults to False.
Returns
Deleted pipelines represented as dict (with key “name”). The return type is a dict [str, str].