diff --git a/commands/operator-sdk/cmd/build.go b/commands/operator-sdk/cmd/build.go new file mode 100644 index 0000000000..fc03afc91b --- /dev/null +++ b/commands/operator-sdk/cmd/build.go @@ -0,0 +1,22 @@ +package cmd + +import "github.com/spf13/cobra" + +// buildCmd represents the build command +var buildCmd = &cobra.Command{ + Use: "build ", + Short: "Compiles code and builds artifacts", + Long: `The operator-sdk build command compiles the code, builds the executables, + and generates Kubernetes manifests. + + is the container image to be built, e.g. "quay.io/example/operator:v0.0.1". + This image will be automatically set in the deployment manifests. + + After build completes, the image would be built locally in docker. Then it needs to + be pushed to remote registry. + For example: + $ operator-sdk build quay.io/example/operator:v0.0.1 + $ docker push quay.io/example/operator:v0.0.1 +`, + Run: newFunc, +}