Note: Please take a look at https://fluxcd.io/docs/contributing/flux/ to find out about how to contribute to Flux and how to interact with the Flux Development team.
Prerequisites:
- go >= 1.16
- kubebuilder >= 2.3
- kustomize >= 3.1
- kubectl >= 1.21
You can run the unit tests by simply doing
make test
Install flux on your test cluster:
flux install
Scale the in-cluster controller to zero:
kubectl -n flux-system scale deployment/kustomize-controller --replicas=0
Port forward to source-controller artifacts server:
kubectl -n flux-system port-forward svc/source-controller 8080:80
Export the local address as SOURCE_CONTROLLER_LOCALHOST
:
export SOURCE_CONTROLLER_LOCALHOST=localhost:8080
Run the controller locally:
make run