Skip to content
This repository has been archived by the owner on Jun 14, 2018. It is now read-only.

istio/old_pilot_repo

Repository files navigation

Development has moved to istio/istio

Istio Pilot

Prow build Status CircleCI Go Report Card GoDoc codecov.io

Istio Pilot provides platform-independant service discovery, and exposes an interface to configure rich L7 routing features such as label based routing across multiple service versions, fault injection, timeouts, retries, circuit breakers. It translates these configurations into sidecar-specific configuration and dynamically reconfigures the sidecars in the service mesh data plane. Platform-specific eccentricities are abstracted and a simplified service discovery interface is presented to the sidecars based on the Envoy data plane API.

Please see Istio's traffic management concepts to learn more about the design of Pilot and the capabilities it provides.

Istio Pilot design gives an architectural overview of its internal components - cluster platform abstractions, service model, and the proxy controllers.

To learn how you can contribute to Istio Pilot, please see the Istio contribution guidelines.

Quick start

  1. Install Bazel: Bazel 0.6.1 or higher. Debian packages are available on Linux. For OS X users, bazel is available via Homebrew.

NOTE 1: Bazel tool is still maturing, and as such has several issues that makes development hard. While setting up Bazel is mostly smooth, it is common to see cryptic errors that prevent you from getting started. Deleting and restarting everything generally helps.

NOTE 2: If you are developing for the Kubernetes platform, for end-to-end integration tests, you need access to a working Kubernetes cluster.

  1. Setup: Run make setup. It installs the required tools and vendorizes the dependencies.

  2. Write code using your favorite IDE. Make sure to format code and run it through the Go linters, before submitting a PR. make fmt to format the code. make lint to run the linters defined in bin/check.sh

    If you add any new source files or import new packages in existing code, make sure to run make gazelle to update the Bazel BUILD files.

  3. Build: Run make build to compile the code.

  4. Unit test: Run make test to run unit tests.

    NOTE: If you are running on OS X, //proxy/envoy:go_default_test will fail. You can ignore this failure.

  5. Dockerize: Run make docker HUB=docker.io/<username> TAG=<sometag>. This will build a docker container for Pilot, the sidecar, and other utilities.

  6. Integration test: Run make e2etest HUB=docker.io/<username> TAG=<sometag> with same image tags as the one you used in the dockerize stage. This step will run end to end integration tests on Kubernetes.

Detailed instructions for testing are available here.