Skip to content

Commit

Permalink
adding new tests for artifactregistry.googleapis.com/Repository (Goog…
Browse files Browse the repository at this point in the history
  • Loading branch information
kotarsky authored and BBBmau committed May 8, 2024
1 parent 26c9704 commit 941dd6f
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
1 change: 1 addition & 0 deletions mmv1/templates/tgc/resource_converters.go.erb
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import (
// N:1 = [ResourceConverter{Convert: convertAbc, merge: mergeAbc}] (len=1)
func ResourceConverters() map[string][]cai.ResourceConverter {
return map[string][]cai.ResourceConverter{
"google_artifact_registry_repository": {artifactregistry.ResourceConverterArtifactRegistryRepository()},
"google_compute_address": {compute.ResourceConverterComputeAddress()},
"google_compute_firewall": {compute.ResourceConverterComputeFirewall()},
"google_compute_disk": {compute.ResourceConverterComputeDisk()},
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
[
{
"name": "//artifactregistry.googleapis.com/projects/{{.Provider.project}}/locations/us-central1/repositories/my-repository",
"ancestry_path": "{{.Ancestry}}/project/{{.Provider.project}}",
"asset_type": "artifactregistry.googleapis.com/Repository",
"resource": {
"version": "v1",
"discovery_document_uri": "https://www.googleapis.com/discovery/v1/apis/artifactregistry/v1/rest",
"discovery_name": "Repository",
"parent": "//cloudresourcemanager.googleapis.com/projects/{{.Provider.project}}",
"data": {
"description": "example docker repository",
"format": "DOCKER",
"mode": "STANDARD_REPOSITORY"
}
},
"ancestors": ["organizations/{{.OrgID}}"]
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
terraform {
required_providers {
google = {
source = "hashicorp/google-beta"
version = "~> {{.Provider.version}}"
}
}
}

provider "google" {
{{if .Provider.credentials }}credentials = "{{.Provider.credentials}}"{{end}}
}

resource "google_artifact_registry_repository" "my-repo" {
location = "us-central1"
repository_id = "my-repository"
description = "example docker repository"
format = "DOCKER"
}

0 comments on commit 941dd6f

Please sign in to comment.