forked from cloudposse/terraform-aws-kms-key
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d7e6abc
commit 7fabc25
Showing
7 changed files
with
248 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,3 +6,6 @@ | |
.terraform/ | ||
.idea | ||
*.iml | ||
|
||
.build-harness | ||
build-harness |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
SHELL := /bin/bash | ||
|
||
# List of targets the `readme` target should call before generating the readme | ||
export README_DEPS ?= docs/targets.md docs/terraform.md | ||
|
||
-include $(shell curl -sSL -o .build-harness "https://git.io/build-harness"; echo .build-harness) | ||
|
||
## Lint terraform code | ||
lint: | ||
$(SELF) terraform/install terraform/get-modules terraform/get-plugins terraform/lint terraform/validate | ||
$(SELF) terraform/install terraform/get-modules terraform/get-plugins terraform/lint terraform/validate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
--- | ||
# | ||
# This is the canonical configuration for the `README.md` | ||
# Run `make readme` to rebuild the `README.md` | ||
# | ||
|
||
# Name of this project | ||
name: terraform-aws-kms-key | ||
|
||
# Logo for this project | ||
#logo: docs/logo.png | ||
|
||
# License of this project | ||
license: "APACHE2" | ||
|
||
# Canonical GitHub repo | ||
github_repo: cloudposse/terraform-aws-kms-key | ||
|
||
# Badges to display | ||
badges: | ||
- name: "Build Status" | ||
image: "https://travis-ci.org/cloudposse/terraform-aws-kms-key.svg?branch=master" | ||
url: "https://travis-ci.org/cloudposse/terraform-aws-kms-key" | ||
- name: "Latest Release" | ||
image: "https://img.shields.io/github/release/cloudposse/terraform-aws-kms-key.svg" | ||
url: "https://github.com/cloudposse/terraform-aws-kms-key/releases/latest" | ||
- name: "Slack Community" | ||
image: "https://slack.cloudposse.com/badge.svg" | ||
url: "https://slack.cloudposse.com" | ||
|
||
related: | ||
- name: "terraform-aws-iam-chamber-user" | ||
description: "Terraform module to provision a basic IAM chamber user with access to SSM parameters and KMS key to decrypt secrets, suitable for CI/CD systems (e.g. TravisCI, CircleCI, CodeFresh) or systems which are external to AWS that cannot leverage AWS IAM Instance Profiles" | ||
url: "https://github.com/cloudposse/terraform-aws-iam-chamber-user" | ||
- name: "terraform-aws-ssm-parameter-store" | ||
description: "Terraform module to populate AWS Systems Manager (SSM) Parameter Store with values from Terraform. Works great with Chamber." | ||
url: "https://github.com/cloudposse/terraform-aws-ssm-parameter-store" | ||
- name: "terraform-aws-ssm-iam-role" | ||
description: "Terraform module to provision an IAM role with configurable permissions to access SSM Parameter Store" | ||
url: "https://github.com/cloudposse/terraform-aws-ssm-iam-role" | ||
|
||
# Short description of this project | ||
description: |- | ||
Terraform module to provision a [KMS](https://aws.amazon.com/kms/) key with alias. | ||
Can be used with [chamber](https://github.com/segmentio/chamber) for managing secrets by storing them in Amazon EC2 Systems Manager Parameter Store. | ||
* https://aws.amazon.com/systems-manager/features | ||
* https://aws.amazon.com/blogs/mt/the-right-way-to-store-secrets-using-parameter-store | ||
# How to use this project | ||
usage: |- | ||
```hcl | ||
module "kms_key" { | ||
source = "git::https://github.com/cloudposse/terraform-aws-kms-key.git?ref=master" | ||
namespace = "cp" | ||
stage = "prod" | ||
name = "app" | ||
description = "KMS key for chamber" | ||
deletion_window_in_days = 10 | ||
enable_key_rotation = "true" | ||
alias = "alias/parameter_store_key" | ||
} | ||
``` | ||
include: | ||
- "docs/targets.md" | ||
- "docs/terraform.md" | ||
|
||
# Contributors to this project | ||
contributors: | ||
- name: "Andriy Knysh" | ||
github: "aknysh" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
## Makefile Targets | ||
``` | ||
Available targets: | ||
help This help screen | ||
help/all Display help for all targets | ||
lint Lint terraform code | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
|
||
## Inputs | ||
|
||
| Name | Description | Type | Default | Required | | ||
|------|-------------|:----:|:-----:|:-----:| | ||
| alias | The display name of the alias. The name must start with the word `alias` followed by a forward slash | string | `` | no | | ||
| attributes | Additional attributes (e.g. `1`) | list | `<list>` | no | | ||
| deletion_window_in_days | Duration in days after which the key is deleted after destruction of the resource | string | `10` | no | | ||
| delimiter | Delimiter to be used between `namespace`, `stage`, `name` and `attributes` | string | `-` | no | | ||
| description | The description of the key as viewed in AWS console | string | `Parameter Store KMS master key` | no | | ||
| enable_key_rotation | Specifies whether key rotation is enabled | string | `true` | no | | ||
| name | Application or solution name (e.g. `app`) | string | - | yes | | ||
| namespace | Namespace (e.g. `cp` or `cloudposse`) | string | - | yes | | ||
| stage | Stage (e.g. `prod`, `dev`, `staging`) | string | - | yes | | ||
| tags | Additional tags (e.g. map(`BusinessUnit`,`XYZ`) | map | `<map>` | no | | ||
|
||
## Outputs | ||
|
||
| Name | Description | | ||
|------|-------------| | ||
| alias_arn | Alias ARN | | ||
| alias_name | Alias name | | ||
| key_arn | Key ARN | | ||
| key_id | Key ID | | ||
|
Oops, something went wrong.