-
Notifications
You must be signed in to change notification settings - Fork 5k
Expand file tree
/
Copy pathregistration.go
More file actions
121 lines (105 loc) · 4.96 KB
/
registration.go
File metadata and controls
121 lines (105 loc) · 4.96 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
// Copyright IBM Corp. 2014, 2025
// SPDX-License-Identifier: MPL-2.0
package storage
import (
"github.com/hashicorp/terraform-plugin-framework/action"
"github.com/hashicorp/terraform-plugin-framework/ephemeral"
"github.com/hashicorp/terraform-provider-azurerm/internal/sdk"
"github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk"
)
type Registration struct{}
var (
_ sdk.UntypedServiceRegistrationWithAGitHubLabel = Registration{}
_ sdk.FrameworkServiceRegistration = Registration{}
)
func (r Registration) AssociatedGitHubLabel() string {
return "service/storage"
}
// Name is the name of this Service
func (r Registration) Name() string {
return "Storage"
}
// WebsiteCategories returns a list of categories which can be used for the sidebar
func (r Registration) WebsiteCategories() []string {
return []string{
"Storage",
}
}
// SupportedDataSources returns the supported Data Sources supported by this Service
func (r Registration) SupportedDataSources() map[string]*pluginsdk.Resource {
return map[string]*pluginsdk.Resource{
"azurerm_storage_account_blob_container_sas": dataSourceStorageAccountBlobContainerSharedAccessSignature(),
"azurerm_storage_account_sas": dataSourceStorageAccountSharedAccessSignature(),
"azurerm_storage_account": dataSourceStorageAccount(),
"azurerm_storage_blob": dataSourceStorageBlob(),
"azurerm_storage_container": dataSourceStorageContainer(),
"azurerm_storage_encryption_scope": dataSourceStorageEncryptionScope(),
"azurerm_storage_management_policy": dataSourceStorageManagementPolicy(),
"azurerm_storage_queue": dataSourceStorageQueue(),
"azurerm_storage_share": dataSourceStorageShare(),
"azurerm_storage_sync": dataSourceStorageSync(),
"azurerm_storage_sync_group": dataSourceStorageSyncGroup(),
"azurerm_storage_table_entity": dataSourceStorageTableEntity(),
}
}
// SupportedResources returns the supported Resources supported by this Service
func (r Registration) SupportedResources() map[string]*pluginsdk.Resource {
return map[string]*pluginsdk.Resource{
"azurerm_storage_account": resourceStorageAccount(),
"azurerm_storage_account_customer_managed_key": resourceStorageAccountCustomerManagedKey(),
"azurerm_storage_account_network_rules": resourceStorageAccountNetworkRules(),
"azurerm_storage_blob": resourceStorageBlob(),
"azurerm_storage_blob_inventory_policy": resourceStorageBlobInventoryPolicy(),
"azurerm_storage_container": resourceStorageContainer(),
"azurerm_storage_encryption_scope": resourceStorageEncryptionScope(),
"azurerm_storage_data_lake_gen2_filesystem": resourceStorageDataLakeGen2FileSystem(),
"azurerm_storage_data_lake_gen2_path": resourceStorageDataLakeGen2Path(),
"azurerm_storage_management_policy": resourceStorageManagementPolicy(),
"azurerm_storage_object_replication": resourceStorageObjectReplication(),
"azurerm_storage_queue": resourceStorageQueue(),
"azurerm_storage_share": resourceStorageShare(),
"azurerm_storage_share_file": resourceStorageShareFile(),
"azurerm_storage_share_directory": resourceStorageShareDirectory(),
"azurerm_storage_table": resourceStorageTable(),
"azurerm_storage_table_entity": resourceStorageTableEntity(),
"azurerm_storage_sync": resourceStorageSync(),
"azurerm_storage_sync_cloud_endpoint": resourceStorageSyncCloudEndpoint(),
"azurerm_storage_sync_group": resourceStorageSyncGroup(),
}
}
func (r Registration) DataSources() []sdk.DataSource {
return []sdk.DataSource{
storageTableDataSource{},
storageTableEntitiesDataSource{},
storageContainersDataSource{},
}
}
func (r Registration) Resources() []sdk.Resource {
return []sdk.Resource{
AccountQueuePropertiesResource{},
AccountStaticWebsiteResource{},
LocalUserResource{},
StorageContainerImmutabilityPolicyResource{},
SyncServerEndpointResource{},
}
}
func (r Registration) Actions() []func() action.Action {
return []func() action.Action{}
}
func (r Registration) FrameworkResources() []sdk.FrameworkWrappedResource {
return []sdk.FrameworkWrappedResource{}
}
func (r Registration) FrameworkDataSources() []sdk.FrameworkWrappedDataSource {
return []sdk.FrameworkWrappedDataSource{}
}
func (r Registration) EphemeralResources() []func() ephemeral.EphemeralResource {
return []func() ephemeral.EphemeralResource{}
}
func (r Registration) ListResources() []sdk.FrameworkListWrappedResource {
return []sdk.FrameworkListWrappedResource{
StorageAccountCustomerManagedKeyListResource{},
StorageAccountListResource{},
StorageSyncListResource{},
SyncServerEndpointListResource{},
}
}