udpate some examples to use external types

This commit is contained in:
David Eads
2018-05-02 16:25:48 -04:00
parent b8aa7baa7d
commit a53a72e238
11 changed files with 159 additions and 42 deletions

View File

@@ -421,7 +421,7 @@ func RunCreateSubcommand(f cmdutil.Factory, options *CreateSubcommandOptions) er
if mapping.Scope.Name() == meta.RESTScopeNameRoot {
namespace = ""
}
actualObject, err := dynamicClient.Resource(mapping.GroupVersionKind.GroupVersion().WithResource(mapping.Resource)).Namespace(namespace).Create(asUnstructured)
actualObject, err := dynamicClient.Resource(mapping.Resource).Namespace(namespace).Create(asUnstructured)
if err != nil {
return err
}