crd-code-generation

module
v0.0.0-...-1fcec39 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 15, 2019 License: Apache-2.0

README

crd-code-generation

Example repository for the blog post Kubernetes Deep Dive: Code Generation for CustomResources.

Installation

export GOPATH=~/go
go get github.com/openshift-evangelists/crd-code-generation

Getting Started

First register the custom resource definition:

kubectl apply -f artifacts/databases-crd.yaml

Then add an example of the Database kind:

kubectl apply -f artifacts/my-database.yaml

Finally build and run the example:

cd ~/go/src/github.com/openshift-evangelists/crd-code-generation/cmd/example/
go build
./example -kubeconfig ~/.kube/config

Directories

Path Synopsis
cmd
pkg
apis/example.com/v1
Package v1 is the v1 version of the API.
Package v1 is the v1 version of the API.
apis/selfcrd/v1
Package v1 is the v1 version of the API.
Package v1 is the v1 version of the API.
client/clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
This package contains the scheme of the automatically generated clientset.
client/clientset/versioned/typed/example/v1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL