kubernetes-operator/doc/developer-guide.md

1.8 KiB

Developer guide

This document explains how to setup your dev environment.

Prerequisites

  • dep version v0.5.0+
  • git
  • go version v1.10+

Download Operator SDK

Go to the jenkins-operator repo and follow the fork guide to fork, clone, and setup the local jenkins-operator repository.

Vendor dependencies

Run the following in the project root directory to update the vendored dependencies:

$ cd $GOPATH/src/github.com/VirtusLab/jenkins-operator
$ make go-dependencies

Build the Operator

Build the Operator jenkins-operator binary:

$ make build

Build the Operator jenkins-operator docker image:

$ make build
$ make docker-build

Run

Run locally with minikube:

$ make minikube-run EXTRA_ARGS='--minikube --local'

Testing

Run unit tests:

$ make test

Run e2e tests with minikube:

$ make minikube-run
$ eval $(minikube docker-env)
$ make docker-build
$ make e2e E2E_IMAGE=<docker-image-builded-locally>

Note: running all tests requires:

See the project README for more details.