cdk-codepipeline-badge-notification
Project description
CDK-CodePipeline-Badge-Notification
Feature
-
Generate badge when AWS CodePipeline state change
-
Update GitHub commit status when AWS CodePipeline state change
-
Notification for chat bot provider
- Slack
- Google Chat
- Telegram
Usage
import { CodePipelineBadgeNotification } from 'cdk-pipeline-badge-notification';
import * as cdk from '@aws-cdk/core';
import * as codePipeline from '@aws-cdk/aws-codepipeline';
const app = new cdk.App();
const env = {
region: process.env.CDK_DEFAULT_REGION,
account: process.env.CDK_DEFAULT_ACCOUNT,
};
const stack = new cdk.Stack(app, 'codepipeline-badge-notification', { env });
const pipeline = new codePipeline.Pipeline(stack, 'TestPipeline', {
pipelineName: 'testCodePipeline',
crossAccountKeys: false,
});
new CodePipelineBadgeNotification(stack, 'CodePipelineBadgeNotification', {
pipelineArn: pipeline.pipelineArn,
gitHubTokenFromSecretsManager: {
secretsManagerArn:
'arn:aws:secretsmanager:ap-northeast-1:111111111111:secret:codepipeline/lambda/github-token-YWWmII',
secretKey: 'codepipeline/lambda/github-token',
},
notification: {
stageName: 'production',
ssmSlackWebHookUrl: '/chat/google/slack',
ssmGoogleChatWebHookUrl: '/chat/google/webhook',
ssmTelegramWebHookUrl: '/chat/telegram/webhook',
},
});
:warning: telegram webhook url from ssm parameter which the URL is not include
text
query string
gitHubTokenFromSecretsManager and notification is optional
Only badge
new CodePipelineBadgeNotification(stack, 'CodePipelineBadgeNotification', {
pipelineArn: pipeline.pipelineArn,
});
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for cdk-codepipeline-badge-notification-1.0.76.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e3652ffbc96e51583c3b9fd100e178ec3d776ddef9947bb14048346933f5d58 |
|
MD5 | 7b99fa76461b0498a7843c658910592c |
|
BLAKE2b-256 | f01e64ef91d26c490f42e1eaa0442315f9eca52d5766c3883cdcb666f81be9bb |
Close
Hashes for cdk_codepipeline_badge_notification-1.0.76-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e41622b5667f522235485e9322eb7abecdbe3508c2bb19914ed9fe0d57bd01be |
|
MD5 | f51d4ceb27e236204c61714964e1eb2e |
|
BLAKE2b-256 | 8fce90fece5dcb85ba31ab43b62e435b5ae9ae9094f524cb3abb099d0fd73323 |