Closed sbose78 closed 4 years ago
Optionally support building from source:
kodo build --source=https://github.com/my/app
Assumption: The source code repo already has a Dockerfile. Example: https://github.com/openshift/ruby-hello-world.git
apiVersion: image.openshift.io/v1 kind: ImageStream metadata: name: my-ruby-image namespace: NAMESPACE
For Golang APIs, use the following imports
imagev1client https://github.com/openshift/client-go/image/clientset/versioned/typed/image/v1
imagev1 "github.com/openshift/api/image/v1"
As a pre-req,
go get github.com/openshift/client-go@584632b8fc73a646310252d82c303f23e325ab4f
apiVersion: build.openshift.io/v1 kind: BuildConfig metadata: name: my-app-docker-build spec: source: type: Git git: uri: 'https://github.com/openshift/ruby-hello-world.git' strategy: type: Docker output: to: kind: ImageStreamTag name: 'my-ruby-image:latest'
buildv1client https://github.com/openshift/client-go/build/clientset/versioned/typed/image/v1
buildv1 "github.com/openshift/api/image/v1"
This PR shows how to create ImageStreams and Builds. https://github.com/cli-playground/kodo/pull/16
What
Optionally support building from source:
How
Assumption: The source code repo already has a Dockerfile. Example: https://github.com/openshift/ruby-hello-world.git
Create an ImageStream
For Golang APIs, use the following imports
imagev1client https://github.com/openshift/client-go/image/clientset/versioned/typed/image/v1
imagev1 "github.com/openshift/api/image/v1"
As a pre-req,
go get github.com/openshift/client-go@584632b8fc73a646310252d82c303f23e325ab4f
Create a BuildConfig
For Golang APIs, use the following imports
buildv1client https://github.com/openshift/client-go/build/clientset/versioned/typed/image/v1
buildv1 "github.com/openshift/api/image/v1"