VK1990
VK1990

Reputation: 11

Creating CI/CD Pipeline using AWS CodePipeline with Bitbucket cloud as the SCM

I am currently looking to create a CI/CD workflow in AWS using AWS CodePipeline using AWS CodeBuild and AWS CloudFormation with Bitbucket Cloud as the SCM. I am looking to implement two pipelines for now in this workflow:

What is it I am looking for?

I am looking for:

  1. An example of creating a connection between AWS CodePipeline and Bitbucket cloud in CloudFormation. I could find something similar for Github being the SCM. I am looking to try the same for Bitbucket cloud as well but just curious if anyone else has implemented something similar already.
  2. Because I have a CI workflow for a pull-request while it is still in "Open" state and the fact that I can have multiple dev branches and hence, multiple PRs could exist simultaneously. So, I would like to know if the CloudFormation configuration accepts any kind of naming pattern for the branch? for ex: feat/**

PS: We are not looking to use bitbucket pipelines for various reasons such as limited number of triggers, not possible to skip certain manual steps in the pipeline, conditional checks on the outcome of certain steps on the pipeline and costs making it unsuitable.

Any pointers or examples on this would be highly appreciated.

Upvotes: 0

Views: 1874

Answers (1)

MederD
MederD

Reputation: 75

Check this out: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-codestarconnections-connection.html

You can use codestar connection for bitbucket: Example:

AWSTemplateFormatVersion: 2010-09-09
Resources:
  SampleConnection:
    Type: 'AWS::CodeStarConnections::Connection'
    Properties:
      ConnectionName: MyConnection
      ProviderType: Bitbucket
      Tags:
        - Key: Project
          Value: ProjectB

Upvotes: 1

Related Questions