Install

Learn how to install and configure StormForge Optimize

There are three parts to StormForge Optimize:

  • redskyctl command line tool
  • StormForge Optimize Controller ( runs in your cluster )
  • API (for those using the StormForge Optimize Platform)

Installing the StormForge Optimize Tool

$ curl -L https://app.stormforge.io/downloads/redskyctl-linux-amd64.tar.gz | tar -xz && \
  sudo mv redskyctl /usr/local/bin/

Using curl

$ curl -L https://app.stormforge.io/downloads/redskyctl-darwin-amd64.tar.gz | tar -xz && \
  sudo mv redskyctl /usr/local/bin/

Or using homebrew

$ brew install redskyops/tap/redskyctl

Binary Releases

Binaries can also be downloaded directly thorugh your browser for macOS and Linux.

Installing the StormForge Optimize Controller

The StormForge Optimize Controller runs inside your Kubernetes cluster. It can be configured to talk to a API for automatic tuning of your application parameters.

Automatic

Our default and preferred method of installation is through our command line tool - redskyctl init. This will deploy the controller, custom resource definitions, and set up necessary RBAC permissions. Using redskyctl init is safe for multiple invocations.

Manual

If direct installation through redskyctl is not possible, installation manifests can be generated. These manifests can then be inspected, checked into source control, or manually applied.

$ redskyctl generate install --output-dir ./install

Helm

If you cannot use redskyctl to install, a basic Helm chart exists. To install using Helm, add the StormForge repository and install the redskyops chart:

$ helm repo add redsky https://redskyops.dev/charts/ && \
  helm repo update && \
  helm install --namespace redsky-system --name redsky redsky/redskyops

The latest release of the Helm chart may not reference the latest application version, use the redskyTag value to override the application version.

API Configuration

To configure the API (e.g. when using the StormForge Optimize platform), you must provide connection parameters through the StormForge Optimize configuration.

Connection Details

To authorize the Red Sky Controller running in your cluster, you must first prepare the necessary credentials on your workstation (i.e. where you run the redskyctl program from). This can be done using a web-based form:

$ redskyctl login

Alternatively, you can get a one-time use code to enter into a browser from another device:

$ redskyctl login --url

At anytime you can check to see that you can communicate with the API:

$ redskyctl ping

Applying Configuration

To apply the StormForge Optimize configuration to the current cluster, first view your existing configuration to verify it is correct:

$ redskyctl config view

This will display the contents of your ~/.config/redsky/config file plus any default values or environment variables that have been set. Your configuration is applied (either created or updated) to the cluster through the redskyctl authorize-cluster command.

$ redskyctl authorize-cluster

Additionally, the redskyctl init command will automatically perform authorization if your connection details are available. If your configuration was valid when you last ran init, there is no need to re-apply your configuration. Once you have verified the configuration, you can ensure your Red Sky Controller deployment is up-to-date:

$ redskyctl init

Alternately, you can store your configuration in the redsky-manager secret of the redsky-system namespace. You can also view this secret to verify the effective configuration values.

Helm Values

If you are installing the StormForge Optimize Controller in your cluster using Helm, you can run redskyctl authorize-cluster --helm-values to produce a values.yaml file with the necessary extra configuration.

Upgrading, Uninstalling, and other Advanced Topics

Upgrading the StormForge Optimize Controller

The preferred way to upgrade the StormForge Optimize Controller is to install the latest version of redskyctl locally and run redskyctl init. Use redskyctl version to check the current version numbers.

In some cases there may be incompatibilities between versions requiring an uninstall prior to the installation of the new version: please consult the release notes for the version you are installing.

Uninstalling the StormForge Optimize Controller

To remove the StormForge Optimize Controller completely from your cluster, run redskyctl reset.

Ensure you have backed up any information in the cluster prior to running this command.

Advanced Installation

Controller installation involves generating manifests and applying them to your cluster using kubectl. If you have specific security requirements, or if the default RBAC configuration for the easy install is too permissive for your environment, or if you just want to inspect the manifests prior to installation, you can obtain the raw StormForge Optimize Controller manifests using the redskyctl command:

$ redskyctl generate install && \
  redskyctl generate controller-rbac

RBAC Requirements

The StormForge Optimize Controller uses Kubernetes jobs to implement trial runs along with custom resources describing the experiment and trial. The StormForge Optimize Controller needs full permission to manipulate these resources. Additionally, the StormForge Optimize Controller must be able to list core pods, services, and namespaces.

The exact permissions required for a particular version can be found by inspecting the output of the redskyctl generate ... commands.

Last modified May 7, 2021