Skip to content

Latest commit

 

History

History

hack

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Hack Scripts

Description

The following are brief summaries for each hack script. Most of these hack scripts accept a --help option to provide information on the different options available.

Starts and stops an OpenShift cluster on AWS as well as provides information about the running OpenShift cluster. You must have an AWS account as well as an OpenShift pull secret to use this.

Used by the Kiali server build targets in order to confirm the version of Go is compatible with Kiali.

Runs the Kiali molecule tests on a Kind Kubernetes cluster. This utilizes kind to start and stop a k8s cluster and the run-molecule-tests.sh script to run the molecule tests. Use this in a cron job to periodically run the molecule tests on kind.

Runs the Kiali molecule tests on a minikube Kubernetes cluster. This utilizes the k8s-minikube.sh script to start and stop a minikube VM and the run-molecule-tests.sh script to run the molecule tests. Use this in a cron job to periodically run the molecule tests on minikube.

Runs the Kiali molecule tests on an existing OpenShift cluster. Utilizes the run-molecule-tests.sh script to run the molecule tests. Use this in a cron job to periodically run the molecule tests.

Configures an installed operator so you can enable and disable operator features (see https://kiali.io/docs/faq/installation/#operator-configuration)

Runs OpenShift on the local machine using CRC.

Creates the necessary resources allowing your cluster to authenticate itself with docker.io when pulling Docker Hub images. This helps avoid the annoying docker.io rate limiting errors.

Makes Go imports pretty in the Go source files.

Deploys an OpenShift cluster in IBM Cloud.

Installs the current community release of Kiali Operator, Kiali Server, and OSSMC via an OLM Subscription and CRs (Kiali CR and OSSMConsole CR). This will optionally install an OpenShift cluster via CRC and also optionally install Istio.

A testing utility that can be used to decode JWT encoded tokens generated by the Kiali server.

A testing utility that can be used to encode JWT tokens. Developers use this to generate unauthorized tokens and pass them to Kiali to try to see if the Kiali authentication mechanism can be thwarted.

Starts and stops a Kubernetes cluster via minikube as well as provides information about the running Kubernetes cluster. This can optionally install Dex OpenID Connect provider which is useful for testing Kiali’s OpenID authentication integration.

Use this to access the Kiali UI that is installed locally in minikube or kind.

Sets up the Kiali performance testing environment in IBM Cloud.

Removes all remnants of Kiali and Kiali Operator from a cluster.

Sets up the environment for the integration tests and runs them. This is the same setup that is used by the CI system.

Note
When running the multi-cluster tests locally, it might be necessary to edit some kernel settings to allow for the kind clusters to be created.

These commands will set the kernel settings temporarily. After a reboot, your system will revert back to its original settings:

sudo sysctl fs.inotify.max_user_watches=524288
sudo sysctl fs.inotify.max_user_instances=512

If you wish to make these settings permanent, the following lines added to your sysctl configuration file should work (depending on your operating system, this configuration file can be something like /etc/sysctl.d/local.conf, /etc/sysctl.conf, or something else. Refer to the man sysctl docs for details):

fs.inotify.max_user_watches=524288
fs.inotify.max_user_instances=512

Runs Kiali on the local machine while having it connect to a remote k8s cluster. This is useful for development and debugging.

Runs the suite of molecule tests on a running OpenShift or minikube cluster.

Runs a local Prometheus in docker and scrapes the Kiali server and operator that is running in an OpenShift cluster.

Creates a KinD cluster for use within GitHub Actions so CI tests can run. Installs Istio and can also set up multiple clusters for multiclster testing.

Starts a kind cluster with metallb as a load balancer implementation.

Creates the necessary resources that enable Istio and Kiali to store and query telemetry data using OpenShift’s built-in Prometheus server.

Running Molecule Tests Periodically

Testing on Minikube

You can do this for a cron job in order to periodically run the Molecule tests on Minikube. If Minikube is not yet started, this script will start one for you (using k8s-minikube.sh) with Dex installed so the OIDC tests can run:

hack/ci-minikube-molecule-tests.sh

There are several options you can pass to that script - pass in --help to see what is applicable for you.

Testing on OpenShift

If you have a cluster running - one that was installed locally via ocp4_setup_upi_kvm - you can do this for a cron job in order to periodically run the Molecule tests:

hack/ci-openshift-molecule-tests.sh

There are several options you can pass to that script - pass in --help to see what is applicable for you.