This part is a work-in-progress because Brigade is still developer-oriented
Brigade is deployed via Helm. Here are the steps:
- Make sure
helmis installed, andhelm versionreturns the correct server. - Add the Brigade repo:
helm repo add brigade https://azure.github.io/brigade - Install Brigade:
helm install brigade/brigade --name brigade-server
At this point, you have a running Brigade service. You can use helm get brigade-server and other Helm tools to examine your running Brigade server.
By default, Brigade is configured to set up a service as a load balancer for your Brigade build system. To find out your IP address, run:
$ kubectl get svc brigade-server-brigade-gw
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
brigade-server-brigade-gw LoadBalancer 10.0.110.59 135.15.52.20 7744:32394/TCP 45d(Note that brigade-server-brigade-gw is just the name of the Helm release (brigade-server) with -brigade-gw appended)
The EXTERNAL-IP field is the IP address that external services, such as GitHub, will use to trigger actions.
Note that this is just one way of configuring Brigade to receive inbound connections. Brigade itself does not care how traffic is routed to it. Those with operational knowledge of Kubernetes may wish to use another method of ingress routing.
You can run Brigade on Minikube for easy testing and development. Minikube provides built-in support for caching and sharing files during builds. However, there are a few things that are much harder to do when running locally:
- Listening for GitHub webhooks requires you to route inbound traffic from the internet to your Minikube cluster. We do not recommend doing this unless you really understand what you are doing.
- Other inbound services may also be limited by the same restriction.
Brigade is well-tested on ACS Kubernetes. We recommend using at least Kubernetes 1.6.
- It is recommended to use a Service with type LoadBalancer on ACS, which will generate an Azure load balancer for you.
- For caching and storage, we recommend creating an Azure Storage instance and
creating a Persistent Volume and Storage Class that use the
AzureFiledriver. - You can use Azure Container Registry for private images, provided that you add the ACR instance to the same Resource Group that ACS belongs to.
- ACR's webhooks can be used to trigger events, as they follow the DockerHub webhook format.
- When configuring webhooks, it is recommended that you map a domain (via Azure's DNS service or another DNS service) to your Load Balancer IP. GitHub and other webhook services seem to work better with DNS names than with IP addresses.