All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.cdklabs.cdk.cicd.wrapper.CDKPipeline Maven / Gradle / Ivy

Go to download

This repository contains the infrastructure as code to wrap your AWS CDK project with CI/CD around it.

There is a newer version: 0.2.12
Show newest version
package io.github.cdklabs.cdk.cicd.wrapper;

/**
 * A construct for creating a CDK pipeline.
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.103.1 (build bef2dea)", date = "2024-09-03T16:35:59.269Z")
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@software.amazon.jsii.Jsii(module = io.github.cdklabs.cdk.cicd.wrapper.$Module.class, fqn = "@cdklabs/cdk-cicd-wrapper.CDKPipeline")
public class CDKPipeline extends software.amazon.awscdk.pipelines.CodePipeline {

    protected CDKPipeline(final software.amazon.jsii.JsiiObjectRef objRef) {
        super(objRef);
    }

    protected CDKPipeline(final software.amazon.jsii.JsiiObject.InitializationMode initializationMode) {
        super(initializationMode);
    }

    static {
        INSTALL_COMMANDS = java.util.Collections.unmodifiableList(software.amazon.jsii.JsiiObject.jsiiStaticGet(io.github.cdklabs.cdk.cicd.wrapper.CDKPipeline.class, "installCommands", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))));
    }

    /**
     * Creates a new instance of the CDKPipeline construct.
     * 

* @param scope The parent construct. This parameter is required. * @param id The ID of the construct. This parameter is required. * @param props The props for configuring the pipeline. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public CDKPipeline(final @org.jetbrains.annotations.NotNull software.constructs.Construct scope, final @org.jetbrains.annotations.NotNull java.lang.String id, final @org.jetbrains.annotations.NotNull io.github.cdklabs.cdk.cicd.wrapper.CDKPipelineProps props) { super(software.amazon.jsii.JsiiObject.InitializationMode.JSII); software.amazon.jsii.JsiiEngine.getInstance().createNewObject(this, new Object[] { java.util.Objects.requireNonNull(scope, "scope is required"), java.util.Objects.requireNonNull(id, "id is required"), java.util.Objects.requireNonNull(props, "props is required") }); } /** * Builds the pipeline by applying necessary configurations and suppressing certain CDK Nag rules. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public void buildPipeline() { software.amazon.jsii.Kernel.call(this, "buildPipeline", software.amazon.jsii.NativeType.VOID); } /** * Default install commands for the pipeline. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public final static java.util.List INSTALL_COMMANDS; /** * A fluent builder for {@link io.github.cdklabs.cdk.cicd.wrapper.CDKPipeline}. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static final class Builder implements software.amazon.jsii.Builder { /** * @return a new instance of {@link Builder}. * @param scope The parent construct. This parameter is required. * @param id The ID of the construct. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static Builder create(final software.constructs.Construct scope, final java.lang.String id) { return new Builder(scope, id); } private final software.constructs.Construct scope; private final java.lang.String id; private final io.github.cdklabs.cdk.cicd.wrapper.CDKPipelineProps.Builder props; private Builder(final software.constructs.Construct scope, final java.lang.String id) { this.scope = scope; this.id = id; this.props = new io.github.cdklabs.cdk.cicd.wrapper.CDKPipelineProps.Builder(); } /** * The branch to be used from the source repository. *

* @return {@code this} * @param branch The branch to be used from the source repository. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder branch(final java.lang.String branch) { this.props.branch(branch); return this; } /** * The CI commands to be executed as part of the Synth step. *

* @return {@code this} * @param ciBuildSpec The CI commands to be executed as part of the Synth step. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder ciBuildSpec(final software.amazon.awscdk.services.codebuild.BuildSpec ciBuildSpec) { this.props.ciBuildSpec(ciBuildSpec); return this; } /** * Default options for CodeBuild projects in the pipeline. *

* @return {@code this} * @param codeBuildDefaults Default options for CodeBuild projects in the pipeline. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder codeBuildDefaults(final software.amazon.awscdk.pipelines.CodeBuildOptions codeBuildDefaults) { this.props.codeBuildDefaults(codeBuildDefaults); return this; } /** * The primary output directory for the synth step. *

* @return {@code this} * @param primaryOutputDirectory The primary output directory for the synth step. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder primaryOutputDirectory(final java.lang.String primaryOutputDirectory) { this.props.primaryOutputDirectory(primaryOutputDirectory); return this; } /** * The source repository for the pipeline. *

* @return {@code this} * @param repositoryInput The source repository for the pipeline. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder repositoryInput(final software.amazon.awscdk.pipelines.IFileSetProducer repositoryInput) { this.props.repositoryInput(repositoryInput); return this; } /** * The Docker image to be used for the build project. *

* @return {@code this} * @param buildImage The Docker image to be used for the build project. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder buildImage(final software.amazon.awscdk.services.codebuild.IBuildImage buildImage) { this.props.buildImage(buildImage); return this; } /** * The severity threshold for CodeGuru security scans. *

* @return {@code this} * @param codeGuruScanThreshold The severity threshold for CodeGuru security scans. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder codeGuruScanThreshold(final io.github.cdklabs.cdk.cicd.wrapper.CodeGuruSeverityThreshold codeGuruScanThreshold) { this.props.codeGuruScanThreshold(codeGuruScanThreshold); return this; } /** * Additional install commands to be executed before the synth step. *

* @return {@code this} * @param installCommands Additional install commands to be executed before the synth step. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder installCommands(final java.util.List installCommands) { this.props.installCommands(installCommands); return this; } /** * Whether Docker should be enabled for synth. *

* Default: false *

* @return {@code this} * @param isDockerEnabledForSynth Whether Docker should be enabled for synth. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder isDockerEnabledForSynth(final java.lang.Boolean isDockerEnabledForSynth) { this.props.isDockerEnabledForSynth(isDockerEnabledForSynth); return this; } /** * Additional Pipeline options. *

* @return {@code this} * @param options Additional Pipeline options. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder options(final io.github.cdklabs.cdk.cicd.wrapper.PipelineOptions options) { this.props.options(options); return this; } /** * Pipeline variables to be passed as environment variables. *

* @return {@code this} * @param pipelineVariables Pipeline variables to be passed as environment variables. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder pipelineVariables(final java.util.Map pipelineVariables) { this.props.pipelineVariables(pipelineVariables); return this; } /** * Default options for the synth CodeBuild project. *

* @return {@code this} * @param synthCodeBuildDefaults Default options for the synth CodeBuild project. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder synthCodeBuildDefaults(final software.amazon.awscdk.pipelines.CodeBuildOptions synthCodeBuildDefaults) { this.props.synthCodeBuildDefaults(synthCodeBuildDefaults); return this; } /** * VPC configuration for the pipeline. *

* @return {@code this} * @param vpcProps VPC configuration for the pipeline. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder vpcProps(final io.github.cdklabs.cdk.cicd.wrapper.VpcProps vpcProps) { this.props.vpcProps(vpcProps); return this; } /** * The qualifier for the application. *

* @return {@code this} * @param applicationQualifier The qualifier for the application. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder applicationQualifier(final java.lang.String applicationQualifier) { this.props.applicationQualifier(applicationQualifier); return this; } /** * The name of the pipeline. *

* @return {@code this} * @param pipelineName The name of the pipeline. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder pipelineName(final java.lang.String pipelineName) { this.props.pipelineName(pipelineName); return this; } /** * Additional IAM policies to be attached to the pipeline role. *

* @return {@code this} * @param rolePolicies Additional IAM policies to be attached to the pipeline role. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder rolePolicies(final java.util.List rolePolicies) { this.props.rolePolicies(rolePolicies); return this; } /** * @return a newly built instance of {@link io.github.cdklabs.cdk.cicd.wrapper.CDKPipeline}. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public io.github.cdklabs.cdk.cicd.wrapper.CDKPipeline build() { return new io.github.cdklabs.cdk.cicd.wrapper.CDKPipeline( this.scope, this.id, this.props.build() ); } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy