Skip to content

Commit

Permalink
cluster_group resource added
Browse files Browse the repository at this point in the history
  • Loading branch information
aktashasan committed Oct 13, 2023
1 parent 588ba14 commit 008d218
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
12 changes: 12 additions & 0 deletions config/cluster_group/config.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package cluster_group

import "github.com/upbound/upjet/pkg/config"

// Configure configures individual resources by adding custom ResourceConfigurators.
func Configure(p *config.Provider) {
p.AddResourceConfigurator("tanzu-mission-control_cluster_group", func(r *config.Resource) {
r.ShortGroup = "tmc"
r.Kind = "Cluster_Group"
r.Version = "v1alpha1"
})
}
1 change: 1 addition & 0 deletions config/external_name.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ var ExternalNameConfigs = map[string]config.ExternalName{
// Import requires using a randomly generated ID from provider: nl-2e21sda
"tanzu-mission-control_akscluster": config.IdentifierFromProvider,
"tanzu-mission-control_cluster": config.IdentifierFromProvider,
"tanzu-mission-control_cluster_group" config.IdentifierFromProvider,

Check failure on line 15 in config/external_name.go

View workflow job for this annotation

GitHub Actions / publish-artifacts

syntax error: unexpected config in composite literal; possibly missing comma or }

Check failure on line 15 in config/external_name.go

View workflow job for this annotation

GitHub Actions / publish-artifacts

syntax error: unexpected config in composite literal; possibly missing comma or }

Check failure on line 15 in config/external_name.go

View workflow job for this annotation

GitHub Actions / unit-tests

syntax error: unexpected config in composite literal; possibly missing comma or }

Check failure on line 15 in config/external_name.go

View workflow job for this annotation

GitHub Actions / local-deploy

syntax error: unexpected config in composite literal; possibly missing comma or }
}

// ExternalNameConfigurations applies all external name configs listed in the
Expand Down
2 changes: 2 additions & 0 deletions config/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import (

akscluster "github.com/ankasoftco/provider-tmc/config/akscluster"
cluster "github.com/ankasoftco/provider-tmc/config/cluster"
cluster_group "github.com/ankasoftco/provider-tmc/config/cluster_group"


)
Expand Down Expand Up @@ -41,6 +42,7 @@ func GetProvider() *ujconfig.Provider {
// add custom config functions
akscluster.Configure,
cluster.Configure,
cluster_group.Configure,

} {
configure(pc)
Expand Down

0 comments on commit 008d218

Please sign in to comment.