lktslionel / aws-codecommit-trigger-pipeline

AWS Serverless Application that triggers an AWS Codepipeline pipeline on CodeCommit Repository State Change

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

status/exprimental

TSKLABS • AWS

AWS Codecommit Trigger Pipeline

AWS Serverless Application that triggers an AWS Codepipeline pipeline on CodeCommit Repository State Change.


Contents


1. Overview

AWS Codecommit Trigger Pipeline is an AWS Serverless Application which is configured to trigger an AWS Codepipeline pipeline as a result of an AWS CodeCommit Repository State Change.

It supports the following AWS Codecommit change events:


2. Quickstart

2.1. Prerequisites

For the application to work, you need:

  • An AWS Account to deploy the application
  • An AWS IAM Role with the necessary permissions to trigger the targetted AWS Codepipeline pipeline.

Note

The built-ins role and permissions provided is, wanted, permissive to ease integration; but make sure to provide another one the the right set of permissions following the Least Priviledge principle.

2.1. Deploy

Before using this application as a trigger for codepipeline, you must deploy the application to the AWS Serverless Application Repository within your AWS Account.

Note

Replace <tag-version> by the release tag version you want to deploy. For instance tag-version should be replaced by A.B.C if you want to deploy the version A.B.C.


Step 1: Download release archive

Go to Releases and download the assets matching the version you want to deploy. Eg: aws-codecommit-trigger-pipeline-v<tag-version>.zip

Step 2: Extract archive

unzip aws-codecommit-trigger-pipeline-vA.B.C.zip
cd $_

Step 3: Authenticate to your AWS Account

Use aws configure to provide the AWS Credentials to the AWS CLI.

Step 4: Deploy the application w/ AWS SAM

sam deploy

2.2. Usage

< Provide instructions on how to use the component >

< Includes releavant commands and code snippets >

< Link 2 to 3 main use cases from 'learning/how-tos or tutorials' to help users understant how to use the component >

2.3. Demo

< Add a short video to demo how it works in a real scenario >

2.4. Uninstall / Unsubscribe

< Add instruction to uninstall the component or unsubscribe to services provided by the component>

Show instructions

Step 1:

Step 2:


3. Learning

3.1. How-tos

< Describe by task basis how to use the component to do one thing >

3.2. Tutorials

< End to end guide to walk you through the steps involved in accomplishing a complete use case >

3.3. Resources


4. Roadmap

< List of Now | Next | Future features planned to improved the component >

4.1. Now

4.2. Next

4.3. Later


5. References

5.1. Concepts

5.2. Motivation

5.3. Testing

5.4. FAQ

FAQ-001:   Question code

sample answer

  code
FAQ-002:   Question code

sample answer

  code
FAQ-003:   Question code

sample answer

  code

6. Contributing

6.1. Instructions

Fork it (yourname/yourproject/fork) Create your feature branch (git checkout -b feature/fooBar) Commit your changes (git commit -am 'Add some fooBar') Push to the branch (git push origin feature/fooBar) Create a new Pull Request

6.3. Build

To build the application, run the following commands

# Install dependencies
pdm install

# Activate virtual env
eval $(pdm venv activate)

#
# Building
#

# Generate requirements.txt with the application dependencies
pdm export --production  -f requirements -o src/aws_codecommit_trigger_pipeline/requirements.txt 

# Build using docker container
sam build --base-dir src --template src/template.yaml --use-container  --no-cached

6.4. Package

zip -r aws-codecommit-trigger-pipeline-vA.B.C-preview.N.zip .aws-sam/build 

6.4. Deliver

Upload `aws-codecommit-trigger-pipeline-vA.B.C-preview.N.zip ` to your artificat repository

6.4. Deploy

  1. Download the artifact from your artifact repositiory aws-codecommit-trigger-pipeline-vA.B.C-preview.N.zip

  2. Run the following command to start de deployment

    sam deploy --stack-name awsctp-aws-codecommit-trigger-pipeline --resolve-s3 --on-failure DELETE --capabilities CAPABILITY_AUTO_EXPAND CAPABILITY_IAM

    with profile:

    sam deploy aws-codecommit-trigger-pipeline-vA.B.C-preview.N.zip --profile sdbx --stack-name awsctp-aws-codecommit-trigger-pipeline --resolve-s3 --on-failure DELETE  --capabilities CAPABILITY_AUTO_EXPAND CAPABILITY_IAM

6.4. Delete

sam delete --profile sdbx --stack-name awsctp-aws-codecommit-trigger-pipeline --no-prompts

6.2. Styleguide


7. Feedback & Support

Tell people where they can go to for help. It can be any combination of an issue tracker, a chat room, an email address, etc.

7.1. Feedback

  • Ask a question on Stack Overflow
  • Request a new feature
  • Upvote popular feature requests
  • File an issue
  • Follow @code and let us know what you think!

7.2. Help


8. Maintainer(s)

Tsklabs Support Team <lktslionel+team/tsklabs@trueskil.co>


9. License

See LICENSE

About

AWS Serverless Application that triggers an AWS Codepipeline pipeline on CodeCommit Repository State Change

License:Apache License 2.0