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.33.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 02accb6227cd93e9e46c10ddd80c611620ce0534d265edcd0e46264757e81481 |
|
MD5 | 89348f12d7620daddc2e42c5c428c872 |
|
BLAKE2b-256 | 21caa773da9ab31bf6209034bce094903ae9de972db4d221e42cf46e0001c95d |
Close
Hashes for cdk_codepipeline_badge_notification-1.0.33-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ddf458db290435059fd5338af2e59378518ae712d0f7549e01732fe7f3fdb0c9 |
|
MD5 | d402608d380f39af1e064c4a6a1cb6ae |
|
BLAKE2b-256 | 5cc81b9af9398097c960f0c52dcdde93dbe793a6e53280ca52b188648a5e3045 |