Terraform module which creates Secret resources on Google Cloud Provider related to SQL databases created with the other modules of this repository.
- AASRE my database is protected by a strong password
- AASRE I can easily access my database password to connect to it
This module is used in mysql module and postgresql module to create password for databases and write them in the secret manager.
No modules.
Name | Description | Type | Default | Required |
---|---|---|---|---|
instance_name | The name of the Cloud SQL resource. | string |
n/a | yes |
project_id | The project ID to manage the Cloud SQL resource. | string |
n/a | yes |
region | The region for the passwords, it should be something like: us-central1-a, us-east1-c, etc. | string |
n/a | yes |
users | List of the users name and their password to store on secret manager. Warning! All those users will be admin and have access to all databases created with this module. | list(string) |
n/a | yes |
create_secrets | Do we create the secrets in secret manager? | bool |
true |
no |
labels | The labels to apply to the secrets. | map(string) |
{} |
no |
Name | Description |
---|---|
secrets | The secrets created for the users. |
users_passwords | The map of users and their passwords. |