Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/hazelops/terraform-aws-sls-app
https://github.com/hazelops/terraform-aws-sls-app
Last synced: 19 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/hazelops/terraform-aws-sls-app
- Owner: hazelops
- License: apache-2.0
- Created: 2022-08-11T09:57:25.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-09-14T21:23:35.000Z (over 1 year ago)
- Last Synced: 2023-09-15T14:13:28.463Z (over 1 year ago)
- Language: HCL
- Size: 20.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Terraform AWS Serverless App Module
Terraform module to create AWS Serverless application.## How to use:
```hcl
module "pecan" {
name = "pecan"
source = "hazelops/sls-app/aws"
env = var.env
vpc_id = module.vpc.vpc_id
public_subnets = module.vpc.public_subnets
private_subnets = module.vpc.private_subnets
security_groups = ["sg-xxxxxxxxxxxxxxxxx"]
parameters = {
"API_KEY": "demo"
}
app_secrets = [
"demo_secret_name"
]global_parameters = {}
global_secrets = []
}
```## Requirements
| Name | Version |
|------|---------|
| [terraform](#requirement\_terraform) | >= 1.0 |
| [aws](#requirement\_aws) | ~> 5.0 |## Providers
| Name | Version |
|------|---------|
| [aws](#provider\_aws) | ~> 5.0 |## Modules
| Name | Source | Version |
|------|--------|---------|
| [global\_secrets](#module\_global\_secrets) | hazelops/ssm-secrets/aws | ~> 1.0 |
| [secrets](#module\_secrets) | hazelops/ssm-secrets/aws | ~> 1.0 |## Resources
| Name | Type |
|------|------|
| [aws_ssm_parameter.sls_global_parameter](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/ssm_parameter) | resource |
| [aws_ssm_parameter.sls_parameter](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/ssm_parameter) | resource |## Inputs
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| [app\_secrets](#input\_app\_secrets) | List of SSM ParameterStore secret parameters - by default, /$var.env/$var.name/* | `list(any)` | `[]` | no |
| [env](#input\_env) | n/a | `any` | n/a | yes |
| [global\_parameters](#input\_global\_parameters) | Map of SSM ParameterStore global parameters to store - by default, /$var.env/global/* | `map(string)` | `{}` | no |
| [global\_secrets](#input\_global\_secrets) | List of SSM ParameterStore global secrets - by default, /$var.env/global/* | `list(any)` | `[]` | no |
| [join\_lists](#input\_join\_lists) | Whether to join lists like subnets and security groups into a one SSM parameter string with comma separator | `bool` | `false` | no |
| [name](#input\_name) | n/a | `any` | n/a | yes |
| [parameters](#input\_parameters) | Map of SSM ParameterStore parameters to store - by default, /$var.env/$var.name/* | `map(string)` | n/a | yes |
| [private\_subnets](#input\_private\_subnets) | VPC Private subnets to place SLS resources | `list(any)` | `[]` | no |
| [public\_subnets](#input\_public\_subnets) | VPC Public subnets to place SLS resources | `list(any)` | `[]` | no |
| [security\_groups](#input\_security\_groups) | Security groups to assign to SLS | `list(any)` | `[]` | no |
| [serialize\_lists](#input\_serialize\_lists) | Whether to serialize lists like subnets and security groups into a one SSM parameter | `bool` | `true` | no |
| [vpc\_id](#input\_vpc\_id) | AWS VPC ID | `string` | `"-"` | no |## Outputs
No outputs.