Skip to content

Commit 25b7d52

Browse files
committed
site deploy settings
1 parent 06ca9fb commit 25b7d52

File tree

11 files changed

+868
-1
lines changed

11 files changed

+868
-1
lines changed

UPDATING_OPENAPI_JSON.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ This project uses a modified `openapi.json`. Please maintain these instructions
1111
1. Remove the `domain` property from the `required` array of the `DnsZone` object.
1212
1. Remove the `values`, `scopes` and `is_secret` parameters from the `updateEnvVar` operation.
1313
1. Add a request body schema to the `updateEnvVar` operation, by copying it from an earlier version of the `openapi.json`.
14-
1. Add a `package_path` property of type string to the `Repo` object.
14+
1. Add a `package_path` property of type `string` to the `Repo` object.
15+
1. Add a `functions_region` property of type `string` to the `Site` object.
16+
1. Add a `cdp_enabled_contexts` property of type `array` of `string`s to the `Site` object.
17+
1. Add a `hud_enabled` property of type `boolean` to the `Site` object.
1518
1. Duplicate the `Site` object into `PartialSite` and remove the `required` properties.
1619
1. Change `updateSite` operation to use the `PartialSite` object as the request body schema (NOTE: not the response body schema).
1720
1. Change the type of `LogDrain.id` to `string`.
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
# generated by https://github.com/hashicorp/terraform-plugin-docs
3+
page_title: "netlify_site_deploy_settings Resource - netlify"
4+
subcategory: ""
5+
description: |-
6+
7+
---
8+
9+
# netlify_site_deploy_settings (Resource)
10+
11+
12+
13+
14+
15+
<!-- schema generated by tfplugindocs -->
16+
## Schema
17+
18+
### Required
19+
20+
- `production_branch` (String)
21+
- `site_id` (String)
22+
23+
### Optional
24+
25+
- `branch_deploy_all_branches` (Boolean)
26+
- `branch_deploy_branches` (List of String)
27+
- `branch_deploy_custom_domain` (String)
28+
- `custom_domain` (String)
29+
- `deploy_preview_custom_domain` (String)
30+
- `deploy_previews` (Boolean)
31+
- `domain_aliases` (List of String)
32+
- `functions_region` (String)
33+
- `netlify_drawer_in_branch_deploys` (Boolean)
34+
- `netlify_drawer_in_deploy_previews` (Boolean)
35+
- `netlify_heads_up_display` (Boolean)
36+
37+
### Read-Only
38+
39+
- `last_updated` (String)

examples/site_settings/main.tf

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,13 @@ resource "netlify_site_build_settings" "platform_test" {
2020
build_command = "npm run build"
2121
publish_directory = "dist"
2222
}
23+
24+
resource "netlify_site_deploy_settings" "platform_test" {
25+
site_id = data.netlify_site.platform_test.id
26+
production_branch = "main"
27+
branch_deploy_branches = ["meow", "woof"]
28+
custom_domain = "platform-test.example-tf-test-test.com"
29+
domain_aliases = ["meow.example-tf-test-test.com"]
30+
branch_deploy_custom_domain = "branch.example-tf-test-test.com"
31+
deploy_preview_custom_domain = "dp.example-tf-test-test.com"
32+
}

internal/netlifyapi/api/openapi.yaml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10311,8 +10311,12 @@ components:
1031110311
id_domain: id_domain
1031210312
deploy_url: deploy_url
1031310313
deploy_hook: deploy_hook
10314+
cdp_enabled_contexts:
10315+
- cdp_enabled_contexts
10316+
- cdp_enabled_contexts
1031410317
created_at: 2000-01-23T04:56:07.000+00:00
1031510318
sso_login_context: sso_login_context
10319+
functions_region: functions_region
1031610320
domain_aliases:
1031710321
- domain_aliases
1031810322
- domain_aliases
@@ -10331,6 +10335,7 @@ components:
1033110335
force_ssl: true
1033210336
notification_email: notification_email
1033310337
capabilities: "{}"
10338+
hud_enabled: true
1033410339
admin_url: admin_url
1033510340
build_settings:
1033610341
repo_type: repo_type
@@ -10464,6 +10469,14 @@ components:
1046410469
items:
1046510470
$ref: '#/components/schemas/SiteLabel'
1046610471
type: array
10472+
functions_region:
10473+
type: string
10474+
cdp_enabled_contexts:
10475+
items:
10476+
type: string
10477+
type: array
10478+
hud_enabled:
10479+
type: boolean
1046710480
required:
1046810481
- account_id
1046910482
- account_name
@@ -10508,8 +10521,12 @@ components:
1050810521
id_domain: id_domain
1050910522
deploy_url: deploy_url
1051010523
deploy_hook: deploy_hook
10524+
cdp_enabled_contexts:
10525+
- cdp_enabled_contexts
10526+
- cdp_enabled_contexts
1051110527
created_at: 2000-01-23T04:56:07.000+00:00
1051210528
sso_login_context: sso_login_context
10529+
functions_region: functions_region
1051310530
domain_aliases:
1051410531
- domain_aliases
1051510532
- domain_aliases
@@ -10528,6 +10545,7 @@ components:
1052810545
force_ssl: true
1052910546
notification_email: notification_email
1053010547
capabilities: "{}"
10548+
hud_enabled: true
1053110549
admin_url: admin_url
1053210550
build_settings:
1053310551
repo_type: repo_type
@@ -10661,6 +10679,14 @@ components:
1066110679
items:
1066210680
$ref: '#/components/schemas/SiteLabel'
1066310681
type: array
10682+
functions_region:
10683+
type: string
10684+
cdp_enabled_contexts:
10685+
items:
10686+
type: string
10687+
type: array
10688+
hud_enabled:
10689+
type: boolean
1066410690
SitesSummary:
1066510691
description: SitesSummary model definition
1066610692
properties:

internal/netlifyapi/model_admin_site.go

Lines changed: 111 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)