-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
azurerm_healthcare_dicom_service
resource & data source - support for new properties
#27375
Changes from 2 commits
89385bf
a7230a0
8605ae6
dbc59ff
3abe99f
b99e007
4506f14
fff7a9e
005ae2a
06a0e6c
e43efe8
c967bc5
a6b433a
cb06e2d
c84092d
dbf0e42
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -7,6 +7,7 @@ import ( | |||||||||||||||||||
"fmt" | ||||||||||||||||||||
"time" | ||||||||||||||||||||
|
||||||||||||||||||||
"github.com/hashicorp/go-azure-helpers/lang/pointer" | ||||||||||||||||||||
"github.com/hashicorp/go-azure-helpers/lang/response" | ||||||||||||||||||||
"github.com/hashicorp/go-azure-helpers/resourcemanager/commonschema" | ||||||||||||||||||||
"github.com/hashicorp/go-azure-helpers/resourcemanager/identity" | ||||||||||||||||||||
|
@@ -86,6 +87,82 @@ func dataSourceHealthcareDicomService() *pluginsdk.Resource { | |||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"data_partitions_enabled": { | ||||||||||||||||||||
Type: pluginsdk.TypeBool, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"cors_configuration": { | ||||||||||||||||||||
Type: pluginsdk.TypeList, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
Elem: &pluginsdk.Resource{ | ||||||||||||||||||||
Schema: map[string]*pluginsdk.Schema{ | ||||||||||||||||||||
"allowed_origins": { | ||||||||||||||||||||
Type: pluginsdk.TypeList, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
Elem: &pluginsdk.Schema{ | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
"allowed_headers": { | ||||||||||||||||||||
Type: pluginsdk.TypeList, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
Elem: &pluginsdk.Schema{ | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
"allowed_methods": { | ||||||||||||||||||||
Type: pluginsdk.TypeList, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
Elem: &pluginsdk.Schema{ | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
"max_age_in_seconds": { | ||||||||||||||||||||
Type: pluginsdk.TypeInt, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
"allow_credentials": { | ||||||||||||||||||||
Type: pluginsdk.TypeBool, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"encryption_key_url": { | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"storage_configuration": { | ||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ditto
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, updated. |
||||||||||||||||||||
Type: pluginsdk.TypeList, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
Elem: &pluginsdk.Resource{ | ||||||||||||||||||||
Schema: map[string]*pluginsdk.Schema{ | ||||||||||||||||||||
"file_system_name": { | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"storage_account_id": { | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"provision_state": { | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
|
||||||||||||||||||||
"event_state": { | ||||||||||||||||||||
Type: pluginsdk.TypeString, | ||||||||||||||||||||
Computed: true, | ||||||||||||||||||||
}, | ||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. These fields contain transient information that isn't meaningful to users, we don't usually expose these in resources or data sources
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, this has been removed from the data source and the docs |
||||||||||||||||||||
|
||||||||||||||||||||
"tags": commonschema.TagsDataSource(), | ||||||||||||||||||||
}, | ||||||||||||||||||||
} | ||||||||||||||||||||
|
@@ -123,6 +200,28 @@ func dataSourceHealthcareApisDicomServiceRead(d *pluginsdk.ResourceData, meta in | |||||||||||||||||||
d.Set("authentication", flattenDicomAuthentication(props.AuthenticationConfiguration)) | ||||||||||||||||||||
d.Set("private_endpoint", flattenDicomServicePrivateEndpoint(props.PrivateEndpointConnections)) | ||||||||||||||||||||
d.Set("service_url", props.ServiceUrl) | ||||||||||||||||||||
|
||||||||||||||||||||
enableDataPartitions := false | ||||||||||||||||||||
if props.EnableDataPartitions != nil { | ||||||||||||||||||||
enableDataPartitions = pointer.From(props.EnableDataPartitions) | ||||||||||||||||||||
} | ||||||||||||||||||||
d.Set("data_partitions_enabled", enableDataPartitions) | ||||||||||||||||||||
|
||||||||||||||||||||
d.Set("cors_configuration", flattenDicomServiceCorsConfiguration(props.CorsConfiguration)) | ||||||||||||||||||||
|
||||||||||||||||||||
if props.Encryption != nil && props.Encryption.CustomerManagedKeyEncryption != nil { | ||||||||||||||||||||
d.Set("encryption_key_url", pointer.From(props.Encryption.CustomerManagedKeyEncryption.KeyEncryptionKeyUrl)) | ||||||||||||||||||||
} | ||||||||||||||||||||
|
||||||||||||||||||||
d.Set("storage_configuration", flattenStorageConfiguration(props.StorageConfiguration)) | ||||||||||||||||||||
|
||||||||||||||||||||
if props.ProvisioningState != nil { | ||||||||||||||||||||
d.Set("provision_state", pointer.From(props.ProvisioningState)) | ||||||||||||||||||||
} | ||||||||||||||||||||
|
||||||||||||||||||||
if props.EventState != nil { | ||||||||||||||||||||
d.Set("event_state", pointer.From(props.EventState)) | ||||||||||||||||||||
} | ||||||||||||||||||||
} | ||||||||||||||||||||
|
||||||||||||||||||||
i, err := identity.FlattenLegacySystemAndUserAssignedMap(m.Identity) | ||||||||||||||||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
configuration is redundant,
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, updated.