2

I am building an application using Lambda, DynamoDB, Cognito, etc.

I want to setup the CI/CD pipeline using AWS tools - AWS codePipeline.

I am using Gitlab for the code repository.

While setting up the build pipeline using Code Pipeline, I found that there is support for Github repositories, but there is No support for Gitlab repositories.

One possible way could, I can use of S3. So when a code is pushed to Gitlab repository, it will be uploaded to S3 bucket.

The codePipeline will trigger the build, execute the test cases and then perform the deployment (Creating lambda functions, API Gateway, DynamoDB tables, etc.)

Is there any better way to integrate CodePipeline with Gitlab?

1
  • This answer may help by mirroring the Gitlab repo, if requirements allow. Commented Apr 21, 2022 at 1:51

3 Answers 3

1

You need to get your code from the 3rd party unsupported Git Repo to S3 from where CodePipeline can take over. This blog [1] provides a way using API Gateway and Lambda to integrate any third party Git Repo with CodePipeline.

[1] https://aws.amazon.com/blogs/devops/integrating-git-with-aws-codepipeline/

Sign up to request clarification or add additional context in comments.

3 Comments

I tried using this guide aws.amazon.com/quickstart/architecture/git-to-s3-using-webhooks to setup the integration between Gitlab and S3. I got an error - Failed to authenticate SSH session: Waiting for USERAUTH response: GitError Is there any document which specifies the changes to be done on Gitlab webhook side?
Add the SSH public key resource "PublicSSHKey" generated by the Cloudformation Stack in the Gitlab user public key settings. Please remember that the public needs to added to each user's account who need to invoke the pipeline when committing a change in the Git repository. The Outputs tab for the CloudFormation stack contain the two webhook endpoint URLs, the output bucket name, and the public SSH key [1]. [1] aws-quickstart.s3.amazonaws.com/quickstart-git2s3/doc/…
URL is showing 404, Any new blog available..?
0

Third-party Git repositories as source for AWS CodePipeline

Kindly check out the above link for the third-party Git repositories as source for AWS CodePipeline

Comments

0

As of Aug 14, 2023:

AWS announced that AWS CodePipeline now supports GitLab as a source control repository.

For more information regarding GitLab integration with AWS Codepipeline check the following reference:

  1. Announcement
  2. GitLab connection

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.