diff --git a/DEVELOPMENT.md b/DEVELOPMENT.md new file mode 100644 index 0000000..f1ee837 --- /dev/null +++ b/DEVELOPMENT.md @@ -0,0 +1,41 @@ +# Development + +This document describes development guidelines for Presto Helm charts. + +## Running locally +[Minikube](https://minikube.sigs.k8s.io) can be used to deploy the chart and run Presto locally for testing purposes. + +The following commands start minikube instance and open Kubernetes cluster dashboard in the default web browser: +```shell +minikube start --cpus=4 --memory=8g --addons=ingress --addons=ingress-dns +minikube dashboard +``` + +## Debugging chart templates + +### Linting +Use `helm lint` to examine the chart by running a series of tests for potential issues or errors. +The command takes a path to the chart and validates that the chart is well-formed. + +For instance, the following command validates Presto Helm chart with enabled Ingress: +```shell +helm lint charts/presto --set ingress.enabled=true +``` + +### Rendering templates +Use `helm template --debug` to render the chart templates locally. + +For example, the command below checks templates correctness with enabled Ingress: +```shell +helm template my-presto charts/presto --set ingress.enabled=true --debug +``` + +### Simulate installation +Use `helm install --dry-run --debug` to simulate the chart installation and print rendered templates. +The command generates manifests and sends them to the Kubernetes API server for verification. +It is useful to check if the chart and configuration are valid for a specific Kubernetes cluster. + +The following command simulates Presto Helm chart installation with enabled Ingress: +```shell +helm install my-presto charts/presto --set ingress.enabled=true --dry-run --debug +``` diff --git a/README.md b/README.md index cb999ac..84ba51e 100644 --- a/README.md +++ b/README.md @@ -2,30 +2,24 @@ [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) -Repository for Presto Helm charts. +Repository for official Presto Helm charts. -## Add Presto charts Helm repo -Use the following command to add Presto charts repository to Helm configuration: +## Helm charts repository +Use the following command to add the repository to Helm client configuration: ```shell -$ helm repo add presto https://prestodb.github.io/presto-helm-charts +helm repo add presto https://prestodb.github.io/presto-helm-charts ``` - -## Debugging chart templates -Use `helm template --debug` to render the chart templates locally, for example, to check correctness when Ingress is enabled: +List the latest stable versions of available Helm charts with the command: ```shell -$ helm template my-presto charts/presto --set ingress.enabled=true --debug +helm search repo presto ``` -Use `helm install --dry-run --debug` to render the chart templates on a server side without creating resources. -The command simulates installation, which is useful to check if the chart and configuration are valid for a specific Kubernetes cluster: -```shell -$ helm install my-presto charts/presto --set ingress.enabled=true --dry-run --debug -``` +## Contributing +Presto welcomes contributions from everyone. -## Running locally -[Minikube](https://minikube.sigs.k8s.io) can be used to deploy the chart and run Presto locally. -The following commands start minikube instance and open Kubernetes cluster dashboard in the default web browser: -```shell -$ minikube start --cpus=4 --memory=8g --addons=ingress --addons=ingress-dns -$ minikube dashboard -``` +Feel free to create an issue with a bug report, feature request or submit a PR. + +Check out [development guidelines](https://github.com/prestodb/presto-helm-charts/blob/main/DEVELOPMENT.md) for local development and testing. + +## Questions +Join [PrestoDB on Slack](https://communityinviter.com/apps/prestodb/prestodb) to ask questions to the community.