ARO HCP Admin API
Overview
Dislcaimer: As the Admin API is currently mostly a stub, so is this README.
The ARO HCP Admin API is a REST API deployed on each regional service cluster, offering a set of endpoints for administrative tasks for SREs and platform operators invoked via Geneva Actions.
Development Workflow
The Admin API can be built and tested locally and in personal DEV environments using a set of Makefile targets.
- make run: runs the Admin API binary locally
- make deploy: builds the admin API container image, uploads it to the DEV service ACR and deploys it to a personal DEV cluster
The Makefile has access to a set of environment variables representing configuration from the config/config.yaml file. The environment variables are made available via the include ../setup-templatize-env.mk directive in the Makefile, which processes and includes the Env.mk file. This is the file you need to modify to provide additional environment variables fueled by config.yaml.
Local Run
Using the make run target, the Admin API binary can be run locally. At this point, the Admin API does not integrate with any other service like the RP Fronent, CS or Maestro. Hence there are no dedicated dependencies on infrastructure that need to be met upfront. This will change soon.
Personal DEV Environment deployment
The local code can also be deployed directly into a personal DEV environment by running make deplioy. Understand that this requires such an environment to be created first via make entrypoint/Region from the root of the repository.
make deploy builds a custom developer image from the local code and uploads it to the DEV service ACR (arohcpsvcdev) into a developer specific repository. This way developer images will not conflict with other develooper images or CI built ones. The actual deployment is delegated to the pipeline/AdminAPI target in the root of the repository, providing a configuration override for adminApi.image.repository and adminApi.image.digest respectively.
Deployment
The pipeline.yaml file in this directory contains the pipeline definition for the Admin API. It is integrated into the topology.yaml file and runs as part of the service cluster deployment.