Kubernetes applications are applications packaged as Helm Charts (Charts). Helm Charts can be shared and stored in a Chart repository. Platform9 Managed Kubernetes includes the stable, incubator, and Fission repositories, by default. The repositories constitute the application catalog.
The following prerequisites must be satisfied before you can deploy a Chart or an application from an application catalog in Platform9 Managed Kubernetes.
- Add a Kubernetes cluster (cluster) with application catalog enabled on the cluster. This is the cluster on which you would to deploy the Chart.
Note: You cannot enable the application catalog on existing clusters.
- Ensure that the repository with the application catalog containing the Chart to deploy is present in Platform9 Managed Kubernetes. If the repository is not already present in Platform9 Managed Kubernetes, you must first add the repository to Platform9 Managed Kubernetes.
- Optionally, define a storage class if the app or Chart requires persistent storage. For example, a database app.
Let us look at each of the prerequisites in detail.
You can add a cluster through the Platform9 Clarity UI. When you add the cluster, you must enable application catalog in the advanced configuration of the cluster creation process.
Follow the steps given below to add a cluster with application catalog enabled on the cluster.
- Navigate to Infrastructure and click Add Cluster to add a new cluster.
- Configure the cluster per your requirement and click Next to move further in the cluster configuration. At step 4, select the Enable Application Catalog check box to enable application catalog.
When a new cluster is added successfully, it has the stable, incubator, and Fission repositories, by default. You can add other repositories to the cluster, if required.
A repository points to a Helm Chart store (Chart store) that contains Kubernetes apps.
When you add a Chart repository, you must name the repository, specify the URL that points to the Chart store, and the URL that points to the source code of the Chart store.
Follow the steps given below to add a repository.
- Navigate to the Repositories tab under App Catalog, and click Add Repository.
- Enter the name, URL and source for the repository. Click Next.
- Optionally, select a cluster to which you want to add the repository.
- Click Add.
The repository is added.
Add Storage Class
You can create a new storage class on a specific cluster by specifying the storage type that maps to the cloud provider for that cluster. This storage class can be used to deploy applications that require persistent storage.
Follow the steps given in Add Storage Class section in Working with Storage Classes in Platform9 Managed Kubernetes to add a new storage class.
The newly added storage class can be used for persistent storage, by the cluster running the application.
Follow the steps given below to deploy an application.
- Navigate to the App Catalog tab under App Catalog.
- Click Deploy on the application to deploy from the application catalog.
- Enter the name of the application, select the namespace to deploy the application and select the application version. Then click Deploy.
- Navigate to the Deployed Apps tab under App Catalog, to check if the app has been deployed successfully.
Alternatively, you can run either of the commands given below, on the command line, to check if the app has been deployed successfully.
You cannot edit the parameters of the Chart through the Platform9 Clarity UI. If you want to edit the Chart's parameters with custom values, you must use the Helm client.
For example, the Jenkins Chart from the stable repository supports several parameters, including Agent.Cpu (default value = 200m) and Agent.Memory (default value = 256Mi). If you want to change these parameters, invoke the Helm client as follows.
Check the README document for the Chart you want to deploy, to get the list of customizable parameters.