Kepler Community Operator on OpenShift
Requirements
Before you start make sure you have:
- An OCP 4.13 cluster running
- Signed in as
kubeadmin
or a user withcluster-admin
role oc
installed.- Cloned the kepler-operator repository.
git clone https://github.com/sustainable-computing-io/kepler-operator.git
cd kepler-operator
Remove previously installed version of the Kepler Community Operator
If you have previously installed the Kepler Community Operator this will need
to be removed prior to the installation of the v0.6.z
version of the operator.
This is due to updates to the Kepler API that not being backward compatible.
To remove the Kepler Operator use the Uninstall Operator Script in the Kepler-Operator repo
- Run the install script to check the installed version of the operator
./hack/uninstall-operator.sh
Sample output of the command
๐๐๐ Resources of Kepler Operator - v0.5.0 ๐๐๐
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Error from server (NotFound): clusterserviceversions.operators.coreos.com "kepler-operator.v0.5.0" not found
๐ failed to find v0.5.0 of kepler-operator.
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
NAME DISPLAY VERSION REPLACES PHASE
kepler-operator.v0.5.0-230815081646 Kepler 0.5.0-230815081646 Succeeded
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ kepler-operator version found are โ๏ธ
- To remove the exiting Kepler Community Operator use the following command, update the -v flag with the operator version that is installed.
/hack/uninstall-operator.sh -v v0.5.0-230815081646 --delete
Install Kepler Community Operator from Operator Hub
- Go to Operators โฏ OperatorHub. Search for
Kepler
. Click on Kepler Operator tile, then selectContinue
and thenInstall
- No changes need to be made to the operator install options, select
Install
- Allow the operator to install
Follow the link to View installed Operators in Namespace openshift-operators
or use the UI to navigate to installed operators and select the Kepler
Operator.
- Select
Create instance
to Create a Custom Resource for Kepler
- Select
Create
. There is aForm
orYAML
view, using the YAML view provides more detail. No changes need to be made.
- Check that the Kepler Exporter pods are running in the
openshift-kepler-operator
namespace
oc project openshift-kepler-operator
oc get pods
A kepler exporter pod should be running on node in the cluster
NAME READY STATUS RESTARTS AGE
kepler-exporter-ds-6j2wm 1/1 Running 0 21s
kepler-exporter-ds-6kd99 1/1 Running 0 21s
kepler-exporter-ds-6lh9x 1/1 Running 0 21s
Installing Kepler Demo Dashboard
The Kepler Dashboard provides demonstration examples of Kepler data. The demo dashboard uses the Grafana Community Operator and some scalability issues have been seen.
Deploy the Grafana Operator
The Kepler demo dashboard is installed using the deploy grafana script in the kepler-operator repo
- Run the deploy grafana script
./hack/dashboard/openshift/deploy-grafana.sh
The script takes a few minutes to complete. The script automates the following steps:
- Setup OpenShift User Project Monitoring
- Install the Grafana Community Operator
- Setup Grafana e.g. ServiceAccount, Grafana DataSource, Grafana Dashboard and Route
When the script successfully completes it provides the OpenShift Route to the Kepler Dashboard
๐๐๐ Grafana Dashboard Setup Complete ๐๐๐
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ฆ Cluster Monitoring Configuration
Backup Directory: /Users/adrianhammond/coding_projects/kepler-operator/tmp/grafana-deployment
๐ Grafana Configuration:
Dashboard URL: https://grafana-route-openshift-kepler-operator.apps.bloomfield.demolab.local/login
Admin: kepler
Password: kepler
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Grafana Dashboard
Sign in to the Grafana dashboard using the credentials kepler:kepler
.
Access the Grafana Console Route
The dashboard can also be accessed through the OCP UI, Go to Networking โฏ Routes.
Grafana Deployment Overview
Refer to the Grafana Deployment Overview
Frequently Asked Questions
Will Kepler work on earlier releases of OpenShift
Our recommendation is use OCP 4.13
but Kepler has been installed on OCP 4.11
and 4.12
. In future the Operator may be updated to check the version of
kubernetes that is installed e.g. v1.25
.