/
graph.go
444 lines (442 loc) · 33.8 KB
/
graph.go
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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
package azurerm
var (
nodeTypes = map[string]struct{}{
"azurerm_advanced_threat_protection": {},
"azurerm_analysis_services_server": {},
"azurerm_api_management": {},
"azurerm_api_management_api": {},
"azurerm_api_management_api_operation": {},
"azurerm_api_management_api_operation_policy": {},
"azurerm_api_management_api_policy": {},
"azurerm_api_management_api_schema": {},
"azurerm_api_management_api_version_set": {},
"azurerm_api_management_authorization_server": {},
"azurerm_api_management_backend": {},
"azurerm_api_management_certificate": {},
"azurerm_api_management_diagnostic": {},
"azurerm_api_management_group": {},
"azurerm_api_management_group_user": {},
"azurerm_api_management_identity_provider_aad": {},
"azurerm_api_management_identity_provider_facebook": {},
"azurerm_api_management_identity_provider_google": {},
"azurerm_api_management_identity_provider_microsoft": {},
"azurerm_api_management_identity_provider_twitter": {},
"azurerm_api_management_logger": {},
"azurerm_api_management_named_value": {},
"azurerm_api_management_openid_connect_provider": {},
"azurerm_api_management_product": {},
"azurerm_api_management_product_api": {},
"azurerm_api_management_product_group": {},
"azurerm_api_management_product_policy": {},
"azurerm_api_management_property": {},
"azurerm_api_management_subscription": {},
"azurerm_api_management_user": {},
"azurerm_app_configuration": {},
"azurerm_app_service": {},
"azurerm_app_service_active_slot": {},
"azurerm_app_service_certificate": {},
"azurerm_app_service_certificate_order": {},
"azurerm_app_service_custom_hostname_binding": {},
"azurerm_app_service_environment": {},
"azurerm_app_service_hybrid_connection": {},
"azurerm_app_service_plan": {},
"azurerm_app_service_slot": {},
"azurerm_app_service_slot_virtual_network_swift_connection": {},
"azurerm_app_service_source_control_token": {},
"azurerm_app_service_virtual_network_swift_connection": {},
"azurerm_application_gateway": {},
"azurerm_application_insights": {},
"azurerm_application_insights_analytics_item": {},
"azurerm_application_insights_api_key": {},
"azurerm_application_insights_web_test": {},
"azurerm_application_security_group": {},
"azurerm_automation_account": {},
"azurerm_automation_certificate": {},
"azurerm_automation_connection": {},
"azurerm_automation_connection_certificate": {},
"azurerm_automation_connection_classic_certificate": {},
"azurerm_automation_connection_service_principal": {},
"azurerm_automation_credential": {},
"azurerm_automation_dsc_configuration": {},
"azurerm_automation_dsc_nodeconfiguration": {},
"azurerm_automation_job_schedule": {},
"azurerm_automation_module": {},
"azurerm_automation_runbook": {},
"azurerm_automation_schedule": {},
"azurerm_automation_variable_bool": {},
"azurerm_automation_variable_datetime": {},
"azurerm_automation_variable_int": {},
"azurerm_automation_variable_string": {},
"azurerm_availability_set": {},
"azurerm_backup_container_storage_account": {},
"azurerm_backup_policy_file_share": {},
"azurerm_backup_policy_vm": {},
"azurerm_backup_protected_file_share": {},
"azurerm_backup_protected_vm": {},
"azurerm_bastion_host": {},
"azurerm_batch_account": {},
"azurerm_batch_application": {},
"azurerm_batch_certificate": {},
"azurerm_batch_pool": {},
"azurerm_blueprint_assignment": {},
"azurerm_bot_channel_directline": {},
"azurerm_bot_channel_email": {},
"azurerm_bot_channel_ms_teams": {},
"azurerm_bot_channel_slack": {},
"azurerm_bot_channels_registration": {},
"azurerm_bot_connection": {},
"azurerm_bot_web_app": {},
"azurerm_cdn_endpoint": {},
"azurerm_cdn_profile": {},
"azurerm_cognitive_account": {},
"azurerm_container_group": {},
"azurerm_container_registry": {},
"azurerm_container_registry_webhook": {},
"azurerm_cosmosdb_account": {},
"azurerm_cosmosdb_cassandra_keyspace": {},
"azurerm_cosmosdb_gremlin_database": {},
"azurerm_cosmosdb_gremlin_graph": {},
"azurerm_cosmosdb_mongo_collection": {},
"azurerm_cosmosdb_mongo_database": {},
"azurerm_cosmosdb_sql_container": {},
"azurerm_cosmosdb_sql_database": {},
"azurerm_cosmosdb_table": {},
"azurerm_cost_management_export_resource_group": {},
"azurerm_custom_provider": {},
"azurerm_dashboard": {},
"azurerm_data_factory": {},
"azurerm_data_factory_dataset_azure_blob": {},
"azurerm_data_factory_dataset_cosmosdb_sqlapi": {},
"azurerm_data_factory_dataset_delimited_text": {},
"azurerm_data_factory_dataset_http": {},
"azurerm_data_factory_dataset_json": {},
"azurerm_data_factory_dataset_mysql": {},
"azurerm_data_factory_dataset_postgresql": {},
"azurerm_data_factory_dataset_sql_server_table": {},
"azurerm_data_factory_integration_runtime_managed": {},
"azurerm_data_factory_integration_runtime_self_hosted": {},
"azurerm_data_factory_linked_service_azure_blob_storage": {},
"azurerm_data_factory_linked_service_azure_file_storage": {},
"azurerm_data_factory_linked_service_azure_function": {},
"azurerm_data_factory_linked_service_cosmosdb": {},
"azurerm_data_factory_linked_service_data_lake_storage_gen2": {},
"azurerm_data_factory_linked_service_key_vault": {},
"azurerm_data_factory_linked_service_mysql": {},
"azurerm_data_factory_linked_service_postgresql": {},
"azurerm_data_factory_linked_service_sftp": {},
"azurerm_data_factory_linked_service_sql_server": {},
"azurerm_data_factory_linked_service_web": {},
"azurerm_data_factory_pipeline": {},
"azurerm_data_factory_trigger_schedule": {},
"azurerm_data_lake_analytics_account": {},
"azurerm_data_lake_analytics_firewall_rule": {},
"azurerm_data_lake_store": {},
"azurerm_data_lake_store_file": {},
"azurerm_data_lake_store_firewall_rule": {},
"azurerm_data_share": {},
"azurerm_data_share_account": {},
"azurerm_data_share_dataset_blob_storage": {},
"azurerm_database_migration_project": {},
"azurerm_database_migration_service": {},
"azurerm_databricks_workspace": {},
"azurerm_dedicated_host": {},
"azurerm_dedicated_host_group": {},
"azurerm_dev_test_global_vm_shutdown_schedule": {},
"azurerm_dev_test_lab": {},
"azurerm_dev_test_linux_virtual_machine": {},
"azurerm_dev_test_policy": {},
"azurerm_dev_test_schedule": {},
"azurerm_dev_test_virtual_network": {},
"azurerm_dev_test_windows_virtual_machine": {},
"azurerm_devspace_controller": {},
"azurerm_disk_encryption_set": {},
"azurerm_dns_a_record": {},
"azurerm_dns_aaaa_record": {},
"azurerm_dns_caa_record": {},
"azurerm_dns_cname_record": {},
"azurerm_dns_mx_record": {},
"azurerm_dns_ns_record": {},
"azurerm_dns_ptr_record": {},
"azurerm_dns_srv_record": {},
"azurerm_dns_txt_record": {},
"azurerm_dns_zone": {},
"azurerm_eventgrid_domain": {},
"azurerm_eventgrid_domain_topic": {},
"azurerm_eventgrid_event_subscription": {},
"azurerm_eventgrid_topic": {},
"azurerm_eventhub": {},
"azurerm_eventhub_authorization_rule": {},
"azurerm_eventhub_cluster": {},
"azurerm_eventhub_consumer_group": {},
"azurerm_eventhub_namespace": {},
"azurerm_eventhub_namespace_authorization_rule": {},
"azurerm_eventhub_namespace_disaster_recovery_config": {},
"azurerm_express_route_circuit": {},
"azurerm_express_route_circuit_authorization": {},
"azurerm_express_route_circuit_peering": {},
"azurerm_express_route_gateway": {},
"azurerm_firewall": {},
"azurerm_firewall_application_rule_collection": {},
"azurerm_firewall_nat_rule_collection": {},
"azurerm_firewall_network_rule_collection": {},
"azurerm_frontdoor": {},
"azurerm_frontdoor_firewall_policy": {},
"azurerm_function_app": {},
"azurerm_function_app_slot": {},
"azurerm_hdinsight_hadoop_cluster": {},
"azurerm_hdinsight_hbase_cluster": {},
"azurerm_hdinsight_interactive_query_cluster": {},
"azurerm_hdinsight_kafka_cluster": {},
"azurerm_hdinsight_ml_services_cluster": {},
"azurerm_hdinsight_rserver_cluster": {},
"azurerm_hdinsight_spark_cluster": {},
"azurerm_hdinsight_storm_cluster": {},
"azurerm_healthcare_service": {},
"azurerm_hpc_cache": {},
"azurerm_hpc_cache_blob_target": {},
"azurerm_hpc_cache_nfs_target": {},
"azurerm_image": {},
"azurerm_iot_time_series_insights_access_policy": {},
"azurerm_iot_time_series_insights_reference_data_set": {},
"azurerm_iot_time_series_insights_standard_environment": {},
"azurerm_iotcentral_application": {},
"azurerm_iothub": {},
"azurerm_iothub_consumer_group": {},
"azurerm_iothub_dps": {},
"azurerm_iothub_dps_certificate": {},
"azurerm_iothub_dps_shared_access_policy": {},
"azurerm_iothub_endpoint_eventhub": {},
"azurerm_iothub_endpoint_servicebus_queue": {},
"azurerm_iothub_endpoint_servicebus_topic": {},
"azurerm_iothub_endpoint_storage_container": {},
"azurerm_iothub_fallback_route": {},
"azurerm_iothub_route": {},
"azurerm_iothub_shared_access_policy": {},
"azurerm_key_vault": {},
"azurerm_key_vault_access_policy": {},
"azurerm_key_vault_certificate": {},
"azurerm_key_vault_certificate_issuer": {},
"azurerm_key_vault_key": {},
"azurerm_key_vault_secret": {},
"azurerm_kubernetes_cluster": {},
"azurerm_kubernetes_cluster_node_pool": {},
"azurerm_kusto_attached_database_configuration": {},
"azurerm_kusto_cluster": {},
"azurerm_kusto_cluster_principal_assignment": {},
"azurerm_kusto_database": {},
"azurerm_kusto_database_principal": {},
"azurerm_kusto_database_principal_assignment": {},
"azurerm_kusto_eventhub_data_connection": {},
"azurerm_lb": {},
"azurerm_lb_backend_address_pool": {},
"azurerm_lb_nat_pool": {},
"azurerm_lb_nat_rule": {},
"azurerm_lb_outbound_rule": {},
"azurerm_lb_probe": {},
"azurerm_lb_rule": {},
"azurerm_linux_virtual_machine": {},
"azurerm_linux_virtual_machine_scale_set": {},
"azurerm_local_network_gateway": {},
"azurerm_log_analytics_datasource_windows_event": {},
"azurerm_log_analytics_datasource_windows_performance_counter": {},
"azurerm_log_analytics_linked_service": {},
"azurerm_log_analytics_solution": {},
"azurerm_log_analytics_workspace": {},
"azurerm_logic_app_action_custom": {},
"azurerm_logic_app_action_http": {},
"azurerm_logic_app_integration_account": {},
"azurerm_logic_app_trigger_custom": {},
"azurerm_logic_app_trigger_http_request": {},
"azurerm_logic_app_trigger_recurrence": {},
"azurerm_logic_app_workflow": {},
"azurerm_machine_learning_workspace": {},
"azurerm_maintenance_assignment_dedicated_host": {},
"azurerm_maintenance_assignment_virtual_machine": {},
"azurerm_maintenance_configuration": {},
"azurerm_managed_application": {},
"azurerm_managed_application_definition": {},
"azurerm_managed_disk": {},
"azurerm_management_group": {},
"azurerm_management_lock": {},
"azurerm_maps_account": {},
"azurerm_mariadb_configuration": {},
"azurerm_mariadb_database": {},
"azurerm_mariadb_firewall_rule": {},
"azurerm_mariadb_server": {},
"azurerm_mariadb_virtual_network_rule": {},
"azurerm_marketplace_agreement": {},
"azurerm_media_services_account": {},
"azurerm_monitor_action_group": {},
"azurerm_monitor_action_rule_action_group": {},
"azurerm_monitor_action_rule_suppression": {},
"azurerm_monitor_activity_log_alert": {},
"azurerm_monitor_autoscale_setting": {},
"azurerm_monitor_diagnostic_setting": {},
"azurerm_monitor_log_profile": {},
"azurerm_monitor_metric_alert": {},
"azurerm_monitor_scheduled_query_rules_alert": {},
"azurerm_monitor_scheduled_query_rules_log": {},
"azurerm_mssql_database": {},
"azurerm_mssql_database_vulnerability_assessment_rule_baseline": {},
"azurerm_mssql_elasticpool": {},
"azurerm_mssql_server": {},
"azurerm_mssql_server_security_alert_policy": {},
"azurerm_mssql_server_vulnerability_assessment": {},
"azurerm_mssql_virtual_machine": {},
"azurerm_mysql_active_directory_administrator": {},
"azurerm_mysql_configuration": {},
"azurerm_mysql_database": {},
"azurerm_mysql_firewall_rule": {},
"azurerm_mysql_server": {},
"azurerm_mysql_virtual_network_rule": {},
"azurerm_nat_gateway": {},
"azurerm_nat_gateway_public_ip_association": {},
"azurerm_netapp_account": {},
"azurerm_netapp_pool": {},
"azurerm_netapp_snapshot": {},
"azurerm_netapp_volume": {},
"azurerm_network_ddos_protection_plan": {},
"azurerm_network_interface_application_gateway_backend_address_pool_association": {},
"azurerm_network_interface_application_security_group_association": {},
"azurerm_network_interface_backend_address_pool_association": {},
"azurerm_network_interface_nat_rule_association": {},
//"azurerm_network_interface_security_group_association": {},
"azurerm_network_packet_capture": {},
"azurerm_network_profile": {},
//"azurerm_network_security_group": {},
//"azurerm_network_security_rule": {},
"azurerm_network_watcher": {},
"azurerm_network_watcher_flow_log": {},
"azurerm_notification_hub": {},
"azurerm_notification_hub_authorization_rule": {},
"azurerm_notification_hub_namespace": {},
"azurerm_orchestrated_virtual_machine_scale_set": {},
"azurerm_packet_capture": {},
"azurerm_point_to_site_vpn_gateway": {},
"azurerm_policy_assignment": {},
"azurerm_policy_definition": {},
"azurerm_policy_remediation": {},
"azurerm_policy_set_definition": {},
"azurerm_postgresql_active_directory_administrator": {},
"azurerm_postgresql_configuration": {},
"azurerm_postgresql_database": {},
"azurerm_postgresql_firewall_rule": {},
"azurerm_postgresql_server": {},
"azurerm_postgresql_virtual_network_rule": {},
"azurerm_powerbi_embedded": {},
"azurerm_private_dns_a_record": {},
"azurerm_private_dns_aaaa_record": {},
"azurerm_private_dns_cname_record": {},
"azurerm_private_dns_mx_record": {},
"azurerm_private_dns_ptr_record": {},
"azurerm_private_dns_srv_record": {},
"azurerm_private_dns_txt_record": {},
"azurerm_private_dns_zone": {},
"azurerm_private_dns_zone_virtual_network_link": {},
"azurerm_private_endpoint": {},
"azurerm_private_link_service": {},
"azurerm_proximity_placement_group": {},
"azurerm_public_ip": {},
"azurerm_public_ip_prefix": {},
"azurerm_recovery_services_vault": {},
"azurerm_redis_cache": {},
"azurerm_redis_firewall_rule": {},
"azurerm_relay_hybrid_connection": {},
"azurerm_relay_namespace": {},
//"azurerm_resource_group": {},
"azurerm_role_assignment": {},
"azurerm_role_definition": {},
"azurerm_route": {},
"azurerm_route_filter": {},
"azurerm_route_table": {},
"azurerm_search_service": {},
"azurerm_security_center_contact": {},
"azurerm_security_center_subscription_pricing": {},
"azurerm_security_center_workspace": {},
"azurerm_sentinel_alert_rule_ms_security_incident": {},
"azurerm_sentinel_alert_rule_scheduled": {},
"azurerm_service_fabric_cluster": {},
"azurerm_servicebus_namespace": {},
"azurerm_servicebus_namespace_authorization_rule": {},
"azurerm_servicebus_namespace_network_rule_set": {},
"azurerm_servicebus_queue": {},
"azurerm_servicebus_queue_authorization_rule": {},
"azurerm_servicebus_subscription": {},
"azurerm_servicebus_subscription_rule": {},
"azurerm_servicebus_topic": {},
"azurerm_servicebus_topic_authorization_rule": {},
"azurerm_shared_image": {},
"azurerm_shared_image_gallery": {},
"azurerm_shared_image_version": {},
"azurerm_signalr_service": {},
"azurerm_site_recovery_fabric": {},
"azurerm_site_recovery_network_mapping": {},
"azurerm_site_recovery_protection_container": {},
"azurerm_site_recovery_protection_container_mapping": {},
"azurerm_site_recovery_replicated_vm": {},
"azurerm_site_recovery_replication_policy": {},
"azurerm_snapshot": {},
"azurerm_spatial_anchors_account": {},
"azurerm_spring_cloud_app": {},
"azurerm_spring_cloud_service": {},
"azurerm_sql_active_directory_administrator": {},
"azurerm_sql_database": {},
"azurerm_sql_elasticpool": {},
"azurerm_sql_failover_group": {},
"azurerm_sql_firewall_rule": {},
"azurerm_sql_server": {},
"azurerm_sql_virtual_network_rule": {},
//"azurerm_storage_account": {},
"azurerm_storage_account_customer_managed_key": {},
"azurerm_storage_account_network_rules": {},
"azurerm_storage_blob": {},
"azurerm_storage_container": {},
"azurerm_storage_data_lake_gen2_filesystem": {},
"azurerm_storage_management_policy": {},
"azurerm_storage_queue": {},
"azurerm_storage_share": {},
"azurerm_storage_share_directory": {},
"azurerm_storage_table": {},
"azurerm_storage_table_entity": {},
"azurerm_stream_analytics_function_javascript_udf": {},
"azurerm_stream_analytics_job": {},
"azurerm_stream_analytics_output_blob": {},
"azurerm_stream_analytics_output_eventhub": {},
"azurerm_stream_analytics_output_mssql": {},
"azurerm_stream_analytics_output_servicebus_queue": {},
"azurerm_stream_analytics_output_servicebus_topic": {},
"azurerm_stream_analytics_reference_input_blob": {},
"azurerm_stream_analytics_stream_input_blob": {},
"azurerm_stream_analytics_stream_input_eventhub": {},
"azurerm_stream_analytics_stream_input_iothub": {},
"azurerm_subnet_nat_gateway_association": {},
"azurerm_subnet_network_security_group_association": {},
"azurerm_subnet_route_table_association": {},
"azurerm_template_deployment": {},
"azurerm_traffic_manager_endpoint": {},
"azurerm_traffic_manager_profile": {},
"azurerm_user_assigned_identity": {},
"azurerm_virtual_hub": {},
"azurerm_virtual_hub_connection": {},
"azurerm_virtual_machine": {},
"azurerm_virtual_machine_data_disk_attachment": {},
"azurerm_virtual_machine_extension": {},
"azurerm_virtual_machine_scale_set": {},
"azurerm_virtual_machine_scale_set_extension": {},
"azurerm_virtual_network_gateway": {},
"azurerm_virtual_network_gateway_connection": {},
"azurerm_virtual_wan": {},
"azurerm_vpn_gateway": {},
"azurerm_vpn_server_configuration": {},
"azurerm_web_application_firewall_policy": {},
"azurerm_windows_virtual_machine": {},
"azurerm_windows_virtual_machine_scale_set": {},
"azurerm_virtual_network": {},
//"azurerm_subnet": {},
//"azurerm_network_interface": {},
}
// edgeTypes map of all the supported Edges
edgeTypes = map[string]struct{}{
"azurerm_virtual_network_peering": {},
}
)