/terraform-aws-codepipeline-slacknotifier

Part of a solution to get ChatOps type functionality from CodeBuild

Primary LanguageHCLGNU General Public License v3.0GPL-3.0

terraform-aws-codepipeline-slacknotifier

Build Status Latest Release GitHub tag (latest SemVer) Terraform Version Infrastructure Tests pre-commit checkov Infrastructure Tests

A collection of AWS resources to send AWS Codebuild build success/failure's to slack using a Lambda function.


It's 100% Open Source and licensed under the APACHE2.

Introduction

AWS Codebuild doesn't have a large ecosystem of plugins like Jenkins or other orchestration tools. This plugin module is intended to give you the basic functionality of notifying a Slack channel with build status's to enable ChatOps. This repository intentionally doesn't include the deployment of the Lambda function which notifies Slack, this is so that many pipelines can utilise one lambda function.

This module will work with the following Slack Notifier lambda function https://github.com/mattchilds1/golang-aws-lambda-slacknotifier.

Usage

Include this repository as a module in your existing terraform code:

  module "slacknotifier" {
    source         = "Path/To/Module"
    function_name  = var.function_name
    pipeline_name  = var.pipeline_name
    environment    = var.environment
  }

see examples folder for examples.

Requirements

No requirements.

Providers

Name Version
aws n/a

Inputs

Name Description Type Default Required
aws_account_no n/a string n/a yes
function_name Name of Lambda function which will be used to notify slack incoming webhook. string n/a yes
kms_master_key_id n/a string "alias/aws/sns" no
pipeline_name Name of the pipeline to send notifications from string n/a yes

Outputs

Name Description
SNS_Topic n/a

Related Projects

Check out these related projects.

Help

Got a question?

File a GitHub issue.

Contributing

Bug Reports & Feature Requests

Please use the issue tracker to report any bugs or file feature requests.

Copyrights

Copyright © 2019-2021 James Woolfenden

License

License

See LICENSE for full details.

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Contributors

Matt Childs
Matt Childs
James Woolfenden
James Woolfenden