Skip to content

Commit

Permalink
firebase
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesWoolfenden committed Jan 29, 2024
1 parent a1307bc commit 9f15702
Show file tree
Hide file tree
Showing 48 changed files with 687 additions and 27 deletions.
27 changes: 3 additions & 24 deletions src/coverage/google.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
# todo google

Resource percentage coverage 12.13
Datasource percentage coverage 90.23
Resource percentage coverage 14.13
Datasource percentage coverage 91.35

./resource.ps1 google_access_context_manager_access_level_condition
./resource.ps1 google_access_context_manager_service_perimeter_resource
./resource.ps1 google_active_directory_domain
./resource.ps1 google_active_directory_domain_trust
./resource.ps1 google_active_directory_peering
./resource.ps1 google_alloydb_backup
./resource.ps1 google_alloydb_cluster
./resource.ps1 google_alloydb_instance
./resource.ps1 google_alloydb_user
./resource.ps1 google_api_gateway_api
./resource.ps1 google_api_gateway_api_config
./resource.ps1 google_api_gateway_api_config_iam_binding
Expand Down Expand Up @@ -87,8 +83,7 @@ Datasource percentage coverage 90.23
./resource.ps1 google_bigquery_table_iam_binding
./resource.ps1 google_bigquery_table_iam_member
./resource.ps1 google_bigquery_table_iam_policy
./resource.ps1 google_bigtable_app_profile
./resource.ps1 google_bigtable_gc_policy

./resource.ps1 google_billing_account_iam_binding
./resource.ps1 google_billing_account_iam_member
./resource.ps1 google_billing_account_iam_policy
Expand Down Expand Up @@ -407,21 +402,8 @@ Datasource percentage coverage 90.23
./resource.ps1 google_filestore_backup
./resource.ps1 google_filestore_instance
./resource.ps1 google_filestore_snapshot
./resource.ps1 google_firebase_android_app
./resource.ps1 google_firebase_apple_app
./resource.ps1 google_firebase_database_instance
./resource.ps1 google_firebase_extensions_instance
./resource.ps1 google_firebase_hosting_channel
./resource.ps1 google_firebase_hosting_custom_domain
./resource.ps1 google_firebase_hosting_release
./resource.ps1 google_firebase_hosting_site
./resource.ps1 google_firebase_hosting_version
./resource.ps1 google_firebase_project
./resource.ps1 google_firebase_project_location
./resource.ps1 google_firebase_storage_bucket
./resource.ps1 google_firebase_web_app
./resource.ps1 google_firebaserules_release
./resource.ps1 google_firebaserules_ruleset
./resource.ps1 google_firestore_backup_schedule
./resource.ps1 google_firestore_database
./resource.ps1 google_firestore_document
Expand Down Expand Up @@ -753,9 +735,6 @@ Datasource percentage coverage 90.23
./resource.ps1 google_container_attached_install_manifest -type data
./resource.ps1 google_container_aws_versions -type data
./resource.ps1 google_container_azure_versions -type data
./resource.ps1 google_data_catalog_taxonomy_iam_policy -type data
./resource.ps1 google_dataform_repository_iam_policy -type data
./resource.ps1 google_endpoints_service_iam_policy -type data
./resource.ps1 google_firebase_web_app_config -type data
./resource.ps1 google_folder -type data
./resource.ps1 google_folder_iam_policy -type data
Expand Down
45 changes: 45 additions & 0 deletions src/files_gcp.go
Original file line number Diff line number Diff line change
Expand Up @@ -267,3 +267,48 @@ var googleAccessContextManagerServicePerimeter []byte

//go:embed mapping/google/resource/accesscontextmanager/google_access_context_manager_service_perimeters.json
var googleAccessContextManagerServicePerimeters []byte

//go:embed mapping/google/resource/alloydb/google_alloydb_backup.json
var googleAlloydbBackup []byte

//go:embed mapping/google/resource/alloydb/google_alloydb_cluster.json
var googleAlloydbCluster []byte

//go:embed mapping/google/resource/alloydb/google_alloydb_instance.json
var googleAlloydbInstance []byte

//go:embed mapping/google/resource/alloydb/google_alloydb_user.json
var googleAlloydbUser []byte

//go:embed mapping/google/resource/firebase/google_firebase_android_app.json
var googleFirebaseAndroidApp []byte

//go:embed mapping/google/resource/firebase/google_firebase_apple_app.json
var googleFirebaseAppleApp []byte

//go:embed mapping/google/resource/firebasedatabase/google_firebase_database_instance.json
var googleFirebaseDatabaseInstance []byte

//go:embed mapping/google/resource/firebasehosting/google_firebase_hosting_site.json
var googleFirebaseHostingSite []byte

//go:embed mapping/google/resource/firebase/google_firebase_project.json
var googleFirebaseProject []byte

//go:embed mapping/google/resource/firebasestorage/google_firebase_storage_bucket.json
var googleFirebaseStorageBucket []byte

//go:embed mapping/google/resource/firebase/google_firebase_android_app.json
var googleFirebaseWebApp []byte

//go:embed mapping/google/resource/firebaserules/google_firebaserules_release.json
var googleFirebaserulesRelease []byte

//go:embed mapping/google/resource/firebaserules/google_firebaserules_ruleset.json
var googleFirebaserulesRuleset []byte

//go:embed mapping/google/resource/bigtable/google_bigtable_app_profile.json
var googleBigtableAppProfile []byte

//go:embed mapping/google/resource/bigtable/google_bigtable_gc_policy.json
var googleBigtableGcPolicy []byte
11 changes: 10 additions & 1 deletion src/files_gcp_datasource.go
Original file line number Diff line number Diff line change
Expand Up @@ -557,4 +557,13 @@ var dataGoogleServiceDirectoryServiceIamPolicy []byte
var dataGoogleSQLBackupRun []byte

//go:embed mapping/google/data/cloudsql/google_sql_database_instance_latest_recovery_time.json
var dataGoogleSqlDatabaseInstanceLatestRecoveryTime []byte
var dataGoogleSQLDatabaseInstanceLatestRecoveryTime []byte

//go:embed mapping/google/data/datacatalog/google_data_catalog_taxonomy_iam_policy.json
var dataGoogleDataCatalogTaxonomyIamPolicy []byte

//go:embed mapping/google/data/dataform/google_dataform_repository_iam_policy.json
var dataGoogleDataformRepositoryIamPolicy []byte

//go:embed mapping/google/data/servicemanagement/google_endpoints_service_iam_policy.json
var dataGoogleEndpointsServiceIamPolicy []byte
19 changes: 19 additions & 0 deletions src/gcp.go
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,25 @@ func GCPLookup(result string) interface{} {
"google_access_context_manager_gcp_user_access_binding": googleAccessContextManagerGcpUserAccessBinding,
"google_access_context_manager_service_perimeter": googleAccessContextManagerServicePerimeter,
"google_access_context_manager_service_perimeters": googleAccessContextManagerServicePerimeters,
"google_alloydb_backup": googleAlloydbBackup,
"google_alloydb_cluster": googleAlloydbCluster,
"google_alloydb_instance": googleAlloydbInstance,
"google_alloydb_user": googleAlloydbUser,
"google_firebase_android_app": googleFirebaseAndroidApp,
"google_firebase_apple_app": googleFirebaseAppleApp,
"google_firebase_database_instance": googleFirebaseDatabaseInstance,
"google_firebase_hosting_channel": googleFirebaseHostingSite,
"google_firebase_hosting_custom_domain": googleFirebaseHostingSite,
"google_firebase_hosting_release": googleFirebaseHostingSite,
"google_firebase_hosting_site": googleFirebaseHostingSite,
"google_firebase_hosting_version": googleFirebaseHostingSite,
"google_firebase_project": googleFirebaseProject,
"google_firebase_storage_bucket": googleFirebaseStorageBucket,
"google_firebase_web_app": googleFirebaseWebApp,
"google_firebaserules_release": googleFirebaserulesRelease,
"google_firebaserules_ruleset": googleFirebaserulesRuleset,
"google_bigtable_app_profile": googleBigtableAppProfile,
"google_bigtable_gc_policy": googleBigtableGcPolicy,
}

return TFLookup[result]
Expand Down
5 changes: 4 additions & 1 deletion src/gcp_datasource.go
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,10 @@ func GCPDataLookup(result string) interface{} {
"google_service_directory_service_iam_policy": dataGoogleServiceDirectoryServiceIamPolicy,
"google_sql_backup_run": dataGoogleSQLBackupRun,
"google_sql_ca_certs": placeholder,
"google_sql_database_instance_latest_recovery_time": dataGoogleSqlDatabaseInstanceLatestRecoveryTime,
"google_sql_database_instance_latest_recovery_time": dataGoogleSQLDatabaseInstanceLatestRecoveryTime,
"google_data_catalog_taxonomy_iam_policy": dataGoogleDataCatalogTaxonomyIamPolicy,
"google_dataform_repository_iam_policy": dataGoogleDataformRepositoryIamPolicy,
"google_endpoints_service_iam_policy": dataGoogleEndpointsServiceIamPolicy,
}

return TFLookup[result]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[
{
"apply": [],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": [
"datacatalog.taxonomies.getIamPolicy"
]
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[
{
"apply": [],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": [
"dataform.repositories.getIamPolicy"
]
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[
{
"apply": [],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": [
"servicemanagement.services.getIamPolicy"
]
}
]
20 changes: 20 additions & 0 deletions src/mapping/google/resource/alloydb/google_alloydb_backup.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[
{
"apply": [
"alloydb.backups.create",
"alloydb.backups.delete",
"alloydb.backups.get",
"alloydb.backups.update"
],
"attributes": {
"tags": []
},
"destroy": [
"alloydb.backups.delete"
],
"modify": [
"alloydb.backups.update"
],
"plan": []
}
]
21 changes: 21 additions & 0 deletions src/mapping/google/resource/alloydb/google_alloydb_cluster.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
[
{
"apply": [
"alloydb.clusters.create",
"alloydb.clusters.delete",
"alloydb.clusters.get",
"alloydb.clusters.update",
"alloydb.operations.get"
],
"attributes": {
"tags": []
},
"destroy": [
"alloydb.clusters.delete"
],
"modify": [
"alloydb.clusters.update"
],
"plan": []
}
]
20 changes: 20 additions & 0 deletions src/mapping/google/resource/alloydb/google_alloydb_instance.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[
{
"apply": [
"alloydb.instances.create",
"alloydb.instances.delete",
"alloydb.instances.get",
"alloydb.instances.update"
],
"attributes": {
"tags": []
},
"destroy": [
"alloydb.instances.delete"
],
"modify": [
"alloydb.instances.update"
],
"plan": []
}
]
20 changes: 20 additions & 0 deletions src/mapping/google/resource/alloydb/google_alloydb_user.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[
{
"apply": [
"alloydb.users.create",
"alloydb.users.delete",
"alloydb.users.get",
"alloydb.users.update"
],
"attributes": {
"tags": []
},
"destroy": [
"alloydb.users.delete"
],
"modify": [
"alloydb.users.update"
],
"plan": []
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[
{
"apply": [
"bigtable.appProfiles.create",
"bigtable.appProfiles.delete",
"bigtable.appProfiles.update",
"bigtable.appProfiles.get"
],
"attributes": {
"tags": []
},
"destroy": [
"bigtable.appProfiles.delete"
],
"modify": [
"bigtable.appProfiles.update"
],
"plan": []
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[
{
"apply": [
"bigtable.tables.update"
],
"attributes": {
"tags": []
},
"destroy": [],
"modify": [],
"plan": []
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"apply": [
"bigtable.instances.create",
"bigtable.instances.get",
"bigtable.instances.list",
"bigtable.clusters.list",
"bigtable.instances.update",
"bigtable.instances.delete"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[
{
"apply": [
"resourcemanager.projects.get",
"serviceusage.services.enable",
"serviceusage.services.get",
"firebase.clients.create",
"firebase.clients.delete",
"firebase.clients.update",
"firebase.clients.get",
"clientauthconfig.clients.get"
],
"attributes": {
"tags": []
},
"destroy": [
"firebase.clients.delete"
],
"modify": [
"firebase.clients.update"
],
"plan": []
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[
{
"apply": [
"resourcemanager.projects.get",
"serviceusage.services.enable",
"serviceusage.services.get",
"firebase.clients.create",
"firebase.clients.delete",
"firebase.clients.update",
"firebase.clients.get",
"clientauthconfig.clients.get"
],
"attributes": {
"tags": []
},
"destroy": [
"firebase.clients.delete"
],
"modify": [
"firebase.clients.update"
],
"plan": []
}
]
Loading

0 comments on commit 9f15702

Please sign in to comment.