How to use where clause in Knex
Create refunds with Stripe
Load HTML with Cheerio
How to send POST request with Axios
Find intersection of array in Lodash
Powered by Official white Bloop logo with a period

Terms / Privacy / Search / Support

  • declare const pipeline: pipelines.CodePipeline;
    const stage = new MyApplicationStage(this, 'MyApplication');
    pipeline.addStage(stage, {
      pre: [
        new pipelines.ConfirmPermissionsBroadening('Check', { stage }),
      ],
    });
    
    Docs
    0
  • declare const pipeline: pipelines.CodePipeline;
    const preprod = new MyApplicationStage(this, 'PreProd');
    const prod = new MyApplicationStage(this, 'Prod');
    
    pipeline.addStage(preprod, {
      post: [
        new pipelines.ShellStep('Validate Endpoint', {
          commands: ['curl -Ssf https://my.webservice.com/'],
        }),
      ],
    });
    pipeline.addStage(prod, {
      pre: [
        new pipelines.ManualApprovalStep('PromoteToProd'),
      ],
    });
    
    Docs
    0
  • declare const pipeline: pipelines.CodePipeline;
    const stage = new MyApplicationStage(this, 'MyApplication');
    pipeline.addStage(stage, {
      pre: [
        new pipelines.ConfirmPermissionsBroadening('Check', { stage }),
      ],
    });
    
    Docs
    0
  • declare const pipeline: pipelines.CodePipeline;
    const preprod = new MyApplicationStage(this, 'PreProd');
    const prod = new MyApplicationStage(this, 'Prod');
    
    pipeline.addStage(preprod, {
      post: [
        new pipelines.ShellStep('Validate Endpoint', {
          commands: ['curl -Ssf https://my.webservice.com/'],
        }),
      ],
    });
    pipeline.addStage(prod, {
      pre: [
        new pipelines.ManualApprovalStep('PromoteToProd'),
      ],
    });
    
    Docs
    0
  • // Modern API
    const modernPipeline = new pipelines.CodePipeline(this, 'Pipeline', {
      selfMutation: false,
      synth: new pipelines.ShellStep('Synth', {
        input: pipelines.CodePipelineSource.connection('my-org/my-app', 'main', {
          connectionArn: 'arn:aws:codestar-connections:us-east-1:222222222222:connection/7d2469ff-514a-4e4f-9003-5ca4a43cdc41', // Created using the AWS console * });',
        }),
        commands: [
          'npm ci',
          'npm run build',
          'npx cdk synth',
        ],
      }),
    });
    
    // Original API
    const cloudAssemblyArtifact = new codepipeline.Artifact();
    const originalPipeline = new pipelines.CdkPipeline(this, 'Pipeline', {
      selfMutating: false,
      cloudAssemblyArtifact,
    });
    
    Docs
    0
  • declare const vpc: ec2.Vpc;
    declare const mySecurityGroup: ec2.SecurityGroup;
    new pipelines.CodePipeline(this, 'Pipeline', {
      // Standard CodePipeline properties
      synth: new pipelines.ShellStep('Synth', {
        input: pipelines.CodePipelineSource.connection('my-org/my-app', 'main', {
          connectionArn: 'arn:aws:codestar-connections:us-east-1:222222222222:connection/7d2469ff-514a-4e4f-9003-5ca4a43cdc41', // Created using the AWS console * });',
        }),
        commands: [
          'npm ci',
          'npm run build',
          'npx cdk synth',
        ],
      }),
    
      // Defaults for all CodeBuild projects
      codeBuildDefaults: {
        // Prepend commands and configuration to all projects
        partialBuildSpec: codebuild.BuildSpec.fromObject({
          version: '0.2',
          // ...
        }),
    
        // Control the build environment
        buildEnvironment: {
          computeType: codebuild.ComputeType.LARGE,
        },
    
        // Control Elastic Network Interface creation
        vpc: vpc,
        subnetSelection: { subnetType: ec2.SubnetType.PRIVATE },
        securityGroups: [mySecurityGroup],
    
        // Additional policy statements for the execution role
        rolePolicy: [
          new iam.PolicyStatement({ /* ... */ }),
        ],
      },
    
      synthCodeBuildDefaults: { /* ... */ },
      assetPublishingCodeBuildDefaults: { /* ... */ },
      selfMutationCodeBuildDefaults: { /* ... */ },
    });
    
    Docs
    0
  • const pipeline = new pipelines.CodePipeline(this, 'Pipeline', {
      synth: new pipelines.ShellStep('Synth', {
        input: pipelines.CodePipelineSource.connection('my-org/my-app', 'main', {
          connectionArn: 'arn:aws:codestar-connections:us-east-1:222222222222:connection/7d2469ff-514a-4e4f-9003-5ca4a43cdc41', // Created using the AWS console * });',
        }),
        commands: ['npm ci','npm run build','npx cdk synth'],
      }),
    
      // Turn this on because the pipeline uses Docker image assets
      dockerEnabledForSelfMutation: true,
    });
    
    pipeline.addWave('MyWave', {
      post: [
        new pipelines.CodeBuildStep('RunApproval', {
          commands: ['command-from-image'],
          buildEnvironment: {
            // The user of a Docker image asset in the pipeline requires turning on
            // 'dockerEnabledForSelfMutation'.
            buildImage: codebuild.LinuxBuildImage.fromAsset(this, 'Image', {
              directory: './docker-image',
            }),
          },
        }),
      ],
    });
    
    Docs
    0
  • const dockerHubSecret = secretsmanager.Secret.fromSecretCompleteArn(this, 'DHSecret', 'arn:aws:...');
    const customRegSecret = secretsmanager.Secret.fromSecretCompleteArn(this, 'CRSecret', 'arn:aws:...');
    const repo1 = ecr.Repository.fromRepositoryArn(this, 'Repo', 'arn:aws:ecr:eu-west-1:0123456789012:repository/Repo1');
    const repo2 = ecr.Repository.fromRepositoryArn(this, 'Repo', 'arn:aws:ecr:eu-west-1:0123456789012:repository/Repo2');
    
    const pipeline = new pipelines.CodePipeline(this, 'Pipeline', {
      dockerCredentials: [
        pipelines.DockerCredential.dockerHub(dockerHubSecret),
        pipelines.DockerCredential.customRegistry('dockerregistry.example.com', customRegSecret),
        pipelines.DockerCredential.ecr([repo1, repo2]),
      ],
      synth: new pipelines.ShellStep('Synth', {
        input: pipelines.CodePipelineSource.connection('my-org/my-app', 'main', {
          connectionArn: 'arn:aws:codestar-connections:us-east-1:222222222222:connection/7d2469ff-514a-4e4f-9003-5ca4a43cdc41', // Created using the AWS console * });',
        }),
        commands: ['npm ci','npm run build','npx cdk synth'],
      }),
    });
    
    Docs
    0
  • declare const pipeline: pipelines.CodePipeline;
    
    const wave = pipeline.addWave('MyWave');
    wave.addStage(new MyApplicationStage(this, 'Stage1'));
    wave.addStage(new MyApplicationStage(this, 'Stage2'));
    
    Docs
    0
  • declare const pipeline: pipelines.CodePipeline;
    
    const wave = pipeline.addWave('MyWave');
    wave.addStage(new MyApplicationStage(this, 'Stage1'));
    wave.addStage(new MyApplicationStage(this, 'Stage2'));
    
    Docs
    0
  • const pipeline = new pipelines.CodePipeline(this, 'Pipeline', {
      synth: new pipelines.ShellStep('Synth', {
        input: pipelines.CodePipelineSource.connection('my-org/my-app', 'main', {
          connectionArn: 'arn:aws:codestar-connections:us-east-1:222222222222:connection/7d2469ff-514a-4e4f-9003-5ca4a43cdc41', // Created using the AWS console * });',
        }),
        commands: ['npm ci','npm run build','npx cdk synth'],
      }),
    
      // Turn this on because the pipeline uses Docker image assets
      dockerEnabledForSelfMutation: true,
    });
    
    pipeline.addWave('MyWave', {
      post: [
        new pipelines.CodeBuildStep('RunApproval', {
          commands: ['command-from-image'],
          buildEnvironment: {
            // The user of a Docker image asset in the pipeline requires turning on
            // 'dockerEnabledForSelfMutation'.
            buildImage: codebuild.LinuxBuildImage.fromAsset(this, 'Image', {
              directory: './docker-image',
            }),
          },
        }),
      ],
    });
    
    Docs
    0
  • Powered by Official black Bloop logo with a period
    download the IDE extension

    View other examples