Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Promote Server Tls Policy to V1 #8073

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .changelog/11538.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
networksecurity: `google_network_security_server_tls_policy` (ga)
```
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ import (
)

func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyBasicExample(t *testing.T) {
acctest.SkipIfVcr(t)
t.Parallel()

context := map[string]interface{}{
Expand All @@ -40,7 +39,7 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyBasicEx

acctest.VcrTest(t, resource.TestCase{
PreCheck: func() { acctest.AccTestPreCheck(t) },
ProtoV5ProviderFactories: acctest.ProtoV5ProviderBetaFactories(t),
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories(t),
CheckDestroy: testAccCheckNetworkSecurityServerTlsPolicyDestroyProducer(t),
Steps: []resource.TestStep{
{
Expand All @@ -59,7 +58,6 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyBasicEx
func testAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyBasicExample(context map[string]interface{}) string {
return acctest.Nprintf(`
resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "tf-test-my-server-tls-policy%{random_suffix}"
labels = {
foo = "bar"
Expand All @@ -77,16 +75,6 @@ resource "google_network_security_server_tls_policy" "default" {
target_uri = "unix:mypath"
}
}
client_validation_ca {
grpc_endpoint {
target_uri = "unix:abc/mypath"
}
}
client_validation_ca {
certificate_provider_instance {
plugin_instance = "google_cloud_private_spiffe"
}
}
}
}
`, context)
Expand All @@ -101,7 +89,7 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyAdvance

acctest.VcrTest(t, resource.TestCase{
PreCheck: func() { acctest.AccTestPreCheck(t) },
ProtoV5ProviderFactories: acctest.ProtoV5ProviderBetaFactories(t),
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories(t),
CheckDestroy: testAccCheckNetworkSecurityServerTlsPolicyDestroyProducer(t),
Steps: []resource.TestStep{
{
Expand All @@ -120,7 +108,6 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyAdvance
func testAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyAdvancedExample(context map[string]interface{}) string {
return acctest.Nprintf(`
resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "tf-test-my-server-tls-policy%{random_suffix}"
labels = {
foo = "bar"
Expand All @@ -144,7 +131,7 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyServerC

acctest.VcrTest(t, resource.TestCase{
PreCheck: func() { acctest.AccTestPreCheck(t) },
ProtoV5ProviderFactories: acctest.ProtoV5ProviderBetaFactories(t),
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories(t),
CheckDestroy: testAccCheckNetworkSecurityServerTlsPolicyDestroyProducer(t),
Steps: []resource.TestStep{
{
Expand All @@ -163,7 +150,6 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyServerC
func testAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyServerCertExample(context map[string]interface{}) string {
return acctest.Nprintf(`
resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "tf-test-my-server-tls-policy%{random_suffix}"
labels = {
foo = "bar"
Expand All @@ -189,7 +175,7 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyMtlsExa

acctest.VcrTest(t, resource.TestCase{
PreCheck: func() { acctest.AccTestPreCheck(t) },
ProtoV5ProviderFactories: acctest.ProtoV5ProviderBetaFactories(t),
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories(t),
CheckDestroy: testAccCheckNetworkSecurityServerTlsPolicyDestroyProducer(t),
Steps: []resource.TestStep{
{
Expand All @@ -208,11 +194,9 @@ func TestAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyMtlsExa
func testAccNetworkSecurityServerTlsPolicy_networkSecurityServerTlsPolicyMtlsExample(context map[string]interface{}) string {
return acctest.Nprintf(`
data "google_project" "project" {
provider = google-beta
}

resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "tf-test-my-server-tls-policy%{random_suffix}"

description = "my description"
Expand All @@ -230,7 +214,6 @@ resource "google_network_security_server_tls_policy" "default" {
}

resource "google_certificate_manager_trust_config" "default" {
provider = google-beta
name = "tf-test-my-trust-config%{random_suffix}"
description = "sample trust config description"
location = "global"
Expand Down
18 changes: 0 additions & 18 deletions website/docs/r/network_security_server_tls_policy.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ description: |-

ClientTlsPolicy is a resource that specifies how a client should authenticate connections to backends of a service. This resource itself does not affect configuration unless it is attached to a backend service resource.

~> **Warning:** This resource is in beta, and should be used with the terraform-provider-google-beta provider.
See [Provider Versions](https://terraform.io/docs/providers/google/guides/provider_versions.html) for more details on beta resources.

To get more information about ServerTlsPolicy, see:

Expand All @@ -38,7 +36,6 @@ To get more information about ServerTlsPolicy, see:

```hcl
resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "my-server-tls-policy"
labels = {
foo = "bar"
Expand All @@ -56,16 +53,6 @@ resource "google_network_security_server_tls_policy" "default" {
target_uri = "unix:mypath"
}
}
client_validation_ca {
grpc_endpoint {
target_uri = "unix:abc/mypath"
}
}
client_validation_ca {
certificate_provider_instance {
plugin_instance = "google_cloud_private_spiffe"
}
}
}
}
```
Expand All @@ -79,7 +66,6 @@ resource "google_network_security_server_tls_policy" "default" {

```hcl
resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "my-server-tls-policy"
labels = {
foo = "bar"
Expand All @@ -102,7 +88,6 @@ resource "google_network_security_server_tls_policy" "default" {

```hcl
resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "my-server-tls-policy"
labels = {
foo = "bar"
Expand All @@ -127,11 +112,9 @@ resource "google_network_security_server_tls_policy" "default" {

```hcl
data "google_project" "project" {
provider = google-beta
}

resource "google_network_security_server_tls_policy" "default" {
provider = google-beta
name = "my-server-tls-policy"

description = "my description"
Expand All @@ -149,7 +132,6 @@ resource "google_network_security_server_tls_policy" "default" {
}

resource "google_certificate_manager_trust_config" "default" {
provider = google-beta
name = "my-trust-config"
description = "sample trust config description"
location = "global"
Expand Down