This is a terraform module that forwards Cloudwatch Alarm SNS messages to matrix-alertmanager
This project is part of the Guardian Project Ops collection.
It's free and open source made available under the the GNU Affero General Public v3 License.
Use this module to receive Cloudwatch alarms in your Matrix rooms.
IMPORTANT: The master branch is used in source just as an example. In your code, do not pin to master because there may be breaking changes between releases.
Instead pin to the release tag (e.g. ?ref=tags/x.y.z) of one of our latest releases.
module "matrix_alertmanager" {
source = "git::https://gitlab.com/guardianproject-ops/terraform-aws-lambda-cloudwatch-matrix-alertmanager.git?ref=master"
matrix_alertmanager_url = "https://example.com?shared_secret=123"
matrix_alertmanager_receiver = "test-room"
sns_topic_arns = [aws_sns_topic.warning.arn]
}| Name | Version |
|---|---|
| archive | ~> 1.3.0 |
| aws | ~> 2.0 |
| null | n/a |
| Name | Description | Type | Default | Required |
|---|---|---|---|---|
| additional_tag_map | Additional tags for appending to tags_as_list_of_maps. Not added to tags. |
map(string) |
{} |
no |
| attributes | Additional attributes (e.g. 1) |
list(string) |
[] |
no |
| build_number | Any time this value changes, the lambda will be rebuilt from source. The value it self has no meaning. | string |
"1" |
no |
| context | Single object for setting entire context at once. See description of individual variables for details. Leave string and numeric variables as null to use default value.Individual variable settings (non-null) override settings in context object, except for attributes, tags, and additional_tag_map, which are merged. |
object({ |
{ |
no |
| delimiter | Delimiter to be used between namespace, environment, stage, name and attributes.Defaults to - (hyphen). Set to "" to use no delimiter at all. |
string |
n/a | yes |
| enabled | Set to false to prevent the module from creating any resources | bool |
n/a | yes |
| environment | Environment, e.g. 'uw2', 'us-west-2', OR 'prod', 'staging', 'dev', 'UAT' | string |
n/a | yes |
| id_length_limit | Limit id to this many characters.Set to 0 for unlimited length.Set to null for default, which is 0.Does not affect id_full. |
number |
n/a | yes |
| label_order | The naming order of the id output and Name tag. Defaults to ["namespace", "environment", "stage", "name", "attributes"]. You can omit any of the 5 elements, but at least one must be present. |
list(string) |
n/a | yes |
| matrix_alertmanager_receiver | The alertmanager receiver to receive the alert | string |
n/a | yes |
| matrix_alertmanager_url | Full URL to the alertmanager matrix endpoint (including query param with shared secret) | string |
n/a | yes |
| name | Solution name, e.g. 'app' or 'jenkins' | string |
n/a | yes |
| namespace | Namespace, which could be your organization name or abbreviation, e.g. 'eg' or 'cp' | string |
n/a | yes |
| regex_replace_chars | Regex to replace chars with empty string in namespace, environment, stage and name.If not set, "/[^a-zA-Z0-9-]/" is used to remove all characters other than hyphens, letters and digits. |
string |
n/a | yes |
| sns_topic_arns | List of sns_topics that will be sending alarms to this lambda | list(string) |
n/a | yes |
| stage | Stage, e.g. 'prod', 'staging', 'dev', OR 'source', 'build', 'test', 'deploy', 'release' | string |
n/a | yes |
| tags | Additional tags (e.g. map('BusinessUnit','XYZ') |
map(string) |
{} |
no |
| Name | Description |
|---|---|
| lambda | the lambda resource output |
| lambda_arn | the lambda resource's arn |
| lambda_qualified_arn | the lambda resource's qualified arn |
Like this project? Please give it a ★ on GitLab
Are you using this project or any of our other projects? Let us know at @guardianproject or email us directly
Check out these related projects.
- terraform-aws-lambda-matrix-alertmanager - Creates a lambda function running matrix-alertmanager
File an issue, send us an email or join us in the Matrix 'verse at #guardianproject:matrix.org or IRC at #guardianproject on Freenode.
Please use the issue tracker to report any bugs or file feature requests.
If you are interested in becoming a contributor, want to get involved in developing this project, other projects, or want to join our team, we would love to hear from you! Shoot us an email.
In general, PRs are welcome. We follow the typical "fork-and-pull" Git workflow.
- Fork the repo on GitLab
- Clone the project to your own machine
- Commit changes to your own branch
- Push your work back up to your fork
- Submit a Merge Request so that we can review your changes
NOTE: Be sure to merge the latest changes from "upstream" before making a pull request!
Copyright © 2017-2020 Guardian Project
GNU AFFERO GENERAL PUBLIC LICENSE
Version 3, 19 November 2007
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
See LICENSE.md for full details.
All other trademarks referenced herein are the property of their respective owners.
This project is maintained and funded by The Guardian Project.
We're a collective of designers and developers focused on useable privacy and security. Everything we do is 100% FOSS. Check out out other ops projects and non-ops projects, follow us on mastadon or twitter, apply for a job, or partner with us.
Abel Luck |
|---|
