Skip to content

Commit 6fd4bb4

Browse files
feat!: Added appsync visibility option, bump AWS provider version to 5.x (#50)
Co-authored-by: Anton Babenko <anton@antonbabenko.com>
1 parent 5c73980 commit 6fd4bb4

File tree

8 files changed

+20
-7
lines changed

8 files changed

+20
-7
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/antonbabenko/pre-commit-terraform
3-
rev: v1.77.0
3+
rev: v1.80.0
44
hooks:
55
- id: terraform_fmt
66
- id: terraform_validate

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ module "appsync" {
1616
1717
schema = file("schema.graphql")
1818
19+
visibility = "GLOBAL"
20+
1921
api_keys = {
2022
default = null # such key will expire in 7 days
2123
}
@@ -112,14 +114,14 @@ $ terraform apply
112114
| Name | Version |
113115
|------|---------|
114116
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
115-
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4.49 |
117+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.1 |
116118
| <a name="requirement_random"></a> [random](#requirement\_random) | >= 2.0 |
117119

118120
## Providers
119121

120122
| Name | Version |
121123
|------|---------|
122-
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 4.49 |
124+
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 5.1 |
123125

124126
## Modules
125127

@@ -188,6 +190,7 @@ No modules.
188190
| <a name="input_schema"></a> [schema](#input\_schema) | The schema definition, in GraphQL schema language format. Terraform cannot perform drift detection of this configuration. | `string` | `""` | no |
189191
| <a name="input_tags"></a> [tags](#input\_tags) | Map of tags to add to all GraphQL resources created by this module | `map(string)` | `{}` | no |
190192
| <a name="input_user_pool_config"></a> [user\_pool\_config](#input\_user\_pool\_config) | The Amazon Cognito User Pool configuration. | `map(string)` | `{}` | no |
193+
| <a name="input_visibility"></a> [visibility](#input\_visibility) | The API visibility. Valid values: GLOBAL, PRIVATE. | `string` | `null` | no |
191194
| <a name="input_xray_enabled"></a> [xray\_enabled](#input\_xray\_enabled) | Whether tracing with X-ray is enabled. | `bool` | `false` | no |
192195

193196
## Outputs

examples/complete/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,14 @@ Note that this example may create resources which cost money. Run `terraform des
2121
| Name | Version |
2222
|------|---------|
2323
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
24-
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4.49 |
24+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.1 |
2525
| <a name="requirement_random"></a> [random](#requirement\_random) | >= 2.0 |
2626

2727
## Providers
2828

2929
| Name | Version |
3030
|------|---------|
31-
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 4.49 |
31+
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 5.1 |
3232
| <a name="provider_random"></a> [random](#provider\_random) | >= 2.0 |
3333

3434
## Modules

examples/complete/main.tf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,8 @@ module "appsync" {
8585

8686
schema = file("schema.graphql")
8787

88+
visibility = "GLOBAL"
89+
8890
domain_name_association_enabled = true
8991
caching_enabled = true
9092

examples/complete/versions.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ terraform {
44
required_providers {
55
aws = {
66
source = "hashicorp/aws"
7-
version = ">= 4.49"
7+
version = ">= 5.1"
88
}
99
random = {
1010
source = "hashicorp/random"

main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ resource "aws_appsync_graphql_api" "this" {
1313
authentication_type = var.authentication_type
1414
schema = var.schema
1515
xray_enabled = var.xray_enabled
16+
visibility = var.visibility
1617

1718
dynamic "log_config" {
1819
for_each = var.logging_enabled ? [true] : []

variables.tf

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ variable "domain_name_association_enabled" {
1515
type = bool
1616
default = false
1717
}
18+
1819
variable "caching_enabled" {
1920
description = "Whether caching with Elasticache is enabled."
2021
type = bool
@@ -39,6 +40,12 @@ variable "schema" {
3940
default = ""
4041
}
4142

43+
variable "visibility" {
44+
description = "The API visibility. Valid values: GLOBAL, PRIVATE."
45+
type = string
46+
default = null
47+
}
48+
4249
variable "authentication_type" {
4350
description = "The authentication type to use by GraphQL API"
4451
type = string

versions.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ terraform {
44
required_providers {
55
aws = {
66
source = "hashicorp/aws"
7-
version = ">= 4.49"
7+
version = ">= 5.1"
88
}
99
random = {
1010
source = "hashicorp/random"

0 commit comments

Comments
 (0)