Skip to content

Commit

Permalink
Add support for parameter manager parameter resource `google_paramete…
Browse files Browse the repository at this point in the history
…r_manager_parameter` (#12630)

[upstream:ef139e7f42d948fdbd9db0db64ceba6b1a8480b0]

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician committed Jan 10, 2025
1 parent 7632a5e commit b972702
Show file tree
Hide file tree
Showing 15 changed files with 1,197 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .changelog/12630.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:new-resource
`google_parameter_manager_parameter`
```
1 change: 1 addition & 0 deletions google-beta/fwmodels/provider_model.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ type ProviderModel struct {
OSConfigCustomEndpoint types.String `tfsdk:"os_config_custom_endpoint"`
OSLoginCustomEndpoint types.String `tfsdk:"os_login_custom_endpoint"`
ParallelstoreCustomEndpoint types.String `tfsdk:"parallelstore_custom_endpoint"`
ParameterManagerCustomEndpoint types.String `tfsdk:"parameter_manager_custom_endpoint"`
ParameterManagerRegionalCustomEndpoint types.String `tfsdk:"parameter_manager_regional_custom_endpoint"`
PrivatecaCustomEndpoint types.String `tfsdk:"privateca_custom_endpoint"`
PrivilegedAccessManagerCustomEndpoint types.String `tfsdk:"privileged_access_manager_custom_endpoint"`
Expand Down
6 changes: 6 additions & 0 deletions google-beta/fwprovider/framework_provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -803,6 +803,12 @@ func (p *FrameworkProvider) Schema(_ context.Context, _ provider.SchemaRequest,
transport_tpg.CustomEndpointValidator(),
},
},
"parameter_manager_custom_endpoint": &schema.StringAttribute{
Optional: true,
Validators: []validator.String{
transport_tpg.CustomEndpointValidator(),
},
},
"parameter_manager_regional_custom_endpoint": &schema.StringAttribute{
Optional: true,
Validators: []validator.String{
Expand Down
6 changes: 6 additions & 0 deletions google-beta/provider/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -683,6 +683,11 @@ func Provider() *schema.Provider {
Optional: true,
ValidateFunc: transport_tpg.ValidateCustomEndpoint,
},
"parameter_manager_custom_endpoint": {
Type: schema.TypeString,
Optional: true,
ValidateFunc: transport_tpg.ValidateCustomEndpoint,
},
"parameter_manager_regional_custom_endpoint": {
Type: schema.TypeString,
Optional: true,
Expand Down Expand Up @@ -1172,6 +1177,7 @@ func ProviderConfigure(ctx context.Context, d *schema.ResourceData, p *schema.Pr
config.OSConfigBasePath = d.Get("os_config_custom_endpoint").(string)
config.OSLoginBasePath = d.Get("os_login_custom_endpoint").(string)
config.ParallelstoreBasePath = d.Get("parallelstore_custom_endpoint").(string)
config.ParameterManagerBasePath = d.Get("parameter_manager_custom_endpoint").(string)
config.ParameterManagerRegionalBasePath = d.Get("parameter_manager_regional_custom_endpoint").(string)
config.PrivatecaBasePath = d.Get("privateca_custom_endpoint").(string)
config.PrivilegedAccessManagerBasePath = d.Get("privileged_access_manager_custom_endpoint").(string)
Expand Down
6 changes: 4 additions & 2 deletions google-beta/provider/provider_mmv1_resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ import (
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/osconfig"
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/oslogin"
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/parallelstore"
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/parametermanager"
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/parametermanagerregional"
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/privateca"
"github.com/hashicorp/terraform-provider-google-beta/google-beta/services/privilegedaccessmanager"
Expand Down Expand Up @@ -515,9 +516,9 @@ var handwrittenIAMDatasources = map[string]*schema.Resource{
}

// Resources
// Generated resources: 582
// Generated resources: 583
// Generated IAM resources: 294
// Total generated resources: 876
// Total generated resources: 877
var generatedResources = map[string]*schema.Resource{
"google_folder_access_approval_settings": accessapproval.ResourceAccessApprovalFolderSettings(),
"google_organization_access_approval_settings": accessapproval.ResourceAccessApprovalOrganizationSettings(),
Expand Down Expand Up @@ -1209,6 +1210,7 @@ var generatedResources = map[string]*schema.Resource{
"google_os_config_patch_deployment": osconfig.ResourceOSConfigPatchDeployment(),
"google_os_login_ssh_public_key": oslogin.ResourceOSLoginSSHPublicKey(),
"google_parallelstore_instance": parallelstore.ResourceParallelstoreInstance(),
"google_parameter_manager_parameter": parametermanager.ResourceParameterManagerParameter(),
"google_parameter_manager_regional_parameter": parametermanagerregional.ResourceParameterManagerRegionalRegionalParameter(),
"google_privateca_ca_pool": privateca.ResourcePrivatecaCaPool(),
"google_privateca_ca_pool_iam_binding": tpgiamresource.ResourceIamBinding(privateca.PrivatecaCaPoolIamSchema, privateca.PrivatecaCaPoolIamUpdaterProducer, privateca.PrivatecaCaPoolIdParseFunc),
Expand Down
Loading

0 comments on commit b972702

Please sign in to comment.