Note: This repository has been archived and its functionality has been merged into a consolidated repository.
For the latest updates and features, please visit the new repository:
This repository holds the configuration files for creating a development environment for everest.
tilt.dev builds and deploys all components to a local kubernetes cluster and also watches for changes in each of the components' repo in order to trigger a rebuild/redeploy of the affected components.
Build and runtime logs can be easily accessed using tilt's web UI.
-
Install k3d
-
Install tilt.dev
-
Clone everest-operator, percona-everest-backend and percona-everest-frontend git repos.
k3d cluster create everest-dev --registry-create k3d-registry
- Setup your default gcloud project, e.g.
export CLOUDSDK_CORE_PROJECT=percona-everest
- Create GKE cluster
gcloud container clusters create <NAME> --cluster-version 1.27 --preemptible --machine-type n1-standard-4 --num-nodes=3 --zone=europe-west1-c --labels delete-cluster-after-hours=12 --no-enable-autoupgrade
- Create Artifacts registry accodring to instructions
- Configure access
gcloud auth configure-docker <REGISTRY_REGION>-docker.pkg.dev
- Uncomment and edit
allow_k8s_contexts
anddefault_registry
in the Tiltfile
- Destroy external cluster when not used
- Cleanup the registry periodically since tilt pushes a new image each time something is changed in the project.
- Set the paths to the local git repos for everest-operator, percona-everest-backend and percona-everest-frontend
export EVEREST_OPERATOR_DIR=<Path to operator repo>
export EVEREST_BACKEND_DIR=<Path to backend repo>
export EVEREST_FRONTEND_DIR=<Path to frontend repo>
export EVEREST_CLI_DIR=<Path to cli repo>
- (Optional) If you want to test a specific version of a given DB operator you can set the following environment variables
export PXC_OPERATOR_VERSION=1.13.0
export PSMDB_OPERATOR_VERSION=1.15.0
export PG_OPERATOR_VERSION=2.3.1
- Run tilt
tilt up
The everest UI/API will be available at http://localhost:8080.
- Tear down tilt
tilt down
- Tear down local k8s cluster
k3d cluster delete everest-dev
Rebuilding the frontend takes ~30s which makes this strategy not very efficient
for frontend development. Therefore, we recommend frontend developers to run
tilt as described in Set up the environment section
but then run a local dev instance of the frontend by running make dev
from
the frontend repo. This dev instance will be available at http://localhost:3000
while still connecting to the everest backend backend running inside k8s.