DISCONTINUATION OF PROJECT.
This project will no longer be maintained by Intel.
Intel has ceased development and contributions including, but not limited to, maintenance, bug fixes, new releases, or updates, to this project.
Intel no longer accepts patches to this project.
If you have an ongoing need to use this project, are interested in independently developing it, or would like to maintain patches for the open source software community, please create your own fork of this project.
-
Controllers to interpret CRDs to Kubernetes-native constructs and report health of those sub-resources.
-
Library and docs for writing controllers that reconcile against CRDs.
The build depends on:
make
docker
docker-compose
(end-to-end tests only)gcloud
(we use the Google Cloud SDK to push images to GCR)
# Build a docker image containing only source dependencies:
$ make dep
# Run library tests, controller tests and build the controller images:
$ make
All builds and tests happen inside of a container. Each controller program
(packages in ./cmd/...
) builds its own result container that can be
deployed in the local integration environment or a target cluster.
There are two intermediate container images:
-
crd-reconciler-for-kubernetes-dep
-- contains only source dependencies, separate to speed up local dev iterations -
crd-reconciler-for-kubernetes
-- base image for all controller images, built on top of crd-reconciler-for-kubernetes-dep.
-
make dep
: Build a docker image containing only source dependencies and tag it ascrd-reconciler-for-kubernetes-dep:$(version)
. This step is a prerequisite to run the other targets, and must be run explicitly. -
make docker
: Build a docker image containing the source repo, running the./pkg/...
tests in the process. -
make controllers
: Build all controller images (also runs tests.) -
make <controller-name>
: Build the controller image (also runs tests.) -
make env-up
andmake env-down
: Bring up/down the integration environment usingdocker-compose
. List service status using e.g.docker-compose ps
. -
make dev TARGET=[test|example-controller...]
: Drop into bash inside the source repo container in the integration environment. Run aftermake env-up
. TARGET defaults to 'test' and can also be set in your SHELL profile -
make test-e2e
: Run the end-to-end integration tests. -
make debug TARGET=[test|example-controller...]
: Attach to the process running in the TARGET container. See tutorial. TARGET defaults to 'test' and can also be set in your SHELL profile
This project uses dep
.
Cheatsheet:
dep ensure
restores source dependenciesdep ensure --add github.com/<foo>/<bar>
adds a new source dependency
After running dep ensure --add
or manually editing Gopkg.toml
,
you must manually re-run make dep
to update your local
crd-reconciler-for-kubernetes-dep
image. Otherwise, the other make targets will
be based off of an outdated set of source dependencies.