1
0
mirror of https://github.com/rancher/types.git synced 2025-08-31 12:48:45 +00:00

A lot of API changes

This commit is contained in:
Darren Shepherd
2017-11-15 16:59:47 -07:00
parent a7111733a5
commit 5bfe5cb7ec
17 changed files with 661 additions and 292 deletions

View File

@@ -2,9 +2,8 @@ package schema
import (
"github.com/rancher/norman/types"
m "github.com/rancher/norman/types/mapping/mapper"
"github.com/rancher/norman/types/factory"
"github.com/rancher/types/apis/cluster.cattle.io/v1"
"github.com/rancher/types/commonmappers"
)
var (
@@ -12,14 +11,9 @@ var (
Version: "v1",
Group: "cluster.cattle.io",
Path: "/v1-cluster",
SubContexts: map[string]bool{
"clusters": true,
},
}
Schemas = commonmappers.Add(&Version, types.NewSchemas()).
AddMapperForType(&Version, v1.Cluster{}, m.NewObject()).
AddMapperForType(&Version, v1.ClusterNode{}, m.NewObject()).
Schemas = factory.Schemas(&Version).
MustImport(&Version, v1.Cluster{}).
MustImport(&Version, v1.ClusterNode{})
)