Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/hazelops/terraform-aws-sls-app


https://github.com/hazelops/terraform-aws-sls-app

Last synced: 19 days ago
JSON representation

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.