Adding a Deliver Artifacts Stage

Add a Deliver Artifacts stage in the build pipeline.

Before you add a stage, you must have a build pipeline.

The Deliver Artifacts stage can't be added as the first stage to a build pipeline. The pipeline must have at least one Managed Build stage first.

Each service in Oracle Cloud Infrastructure (OCI) integrates with Identity and Access Management (IAM) for authentication and authorization. For creating dynamic groups and policies for adding a Deliver Artifacts stage to the build pipeline, see Artifact Policies. For more details, see DevOps IAM Policies.

To store the Managed Build stage output, create either a Container Registry repository or an Artifact Registry repository. In Container Registry repository Docker images are stored and in Artifact Registry repository you can store generic software packages.

  • For accessing DevOps using the Oracle Cloud Console, REST API, and CLI, see Accessing DevOps.

    1. Open the navigation menu and click Developer Services. Under DevOps, click Projects.
    2. Select a project and a build pipeline.
    3. Click the + icon located after the Managed Build stage.
    4. To add the stage sequentially, select Add stage, or select Add parallel stage.
    5. For the stage type, select Deliver Artifacts, and then click Next.
    6. Enter a name and description for the stage. Adding a description is optional.
    7. Click Select Artifact, and then select one or more artifacts associated with your DevOps project.
    8. To add new artifact sources, click Create Artifact. See Managing Artifacts.
    9. For Build config/result Artifact name under Associate Artifacts with Build Result, enter the value of outputArtifact given in your build specification file.
    10. (Optional) To add tags to the stage, click Show tagging options. Tagging is a metadata system that lets you organize and track the resources in your tenancy.

      If you have permissions to create a resource, you also have permissions to add free-form tags to it.

      To add a defined tag, you must have permissions to use the tag namespace.

      For more information, see Resource Tags.

    11. To add the stage to the pipeline, click Add.

      A stage preview provides a snapshot of the configuration.

    You can add the following stages sequentially or in parallel to the pipeline:
    • Trigger Deployment: Start a deployment pipeline to deploy the output from the build pipeline.
    • Wait: Pause a specific duration for testing the build pipeline.

    You can manually run the build or automatically trigger a build run when you commit your changes to the code repository.

  • To create a build pipeline, run the create command:

    oci devops build-pipeline create --project-id

    To add a Deliver Artifacts stage for the pipeline, run the create-deliver-artifact-stage command:

    oci devops build-pipeline-stage create-deliver-artifact-stage

    Required parameters are:

    • --build-pipeline-id
    • --deliver-artifact-collection
    • --stage-predecessor-collection

    To get all the commands for build-pipeline and build-pipeline-stage:

    oci devops build-pipeline -h
    oci devops build-pipeline-stage -h

    To get help for the create-deliver-artifact-stage command:

    oci devops build-pipeline-stage create-deliver-artifact-stage -h
  • To create a build pipeline, use the CreateBuildPipeline operation.

    To add a Deliver Artifacts stage for the pipeline, use the CreateBuildPipelineStage operation. For the buildPipelineStageType attribute, specify the value as DELIVER_ARTIFACT.