diff --git a/charts/gitvote/Chart.yaml b/charts/gitvote/Chart.yaml index 7386072..cfda4f0 100644 --- a/charts/gitvote/Chart.yaml +++ b/charts/gitvote/Chart.yaml @@ -2,9 +2,11 @@ apiVersion: v2 name: gitvote description: GitVote is a GitHub application that allows holding a vote on issues and pull requests type: application -version: 0.1.0 -appVersion: 0.1.0 +version: 0.2.0 +appVersion: 0.2.0 kubeVersion: ">= 1.19.0-0" +home: https://gitvote.dev +icon: https://raw.githubusercontent.com/cncf/gitvote/main/docs/logo/logo.png keywords: - git - vote @@ -18,3 +20,19 @@ dependencies: version: 8.2.1 repository: https://charts.helm.sh/stable condition: postgresql.enabled +annotations: + artifacthub.io/category: skip-prediction + artifacthub.io/changes: | + - kind: added + description: Initial version + artifacthub.io/containsSecurityUpdates: "true" + artifacthub.io/images: | + - name: dbmigrator + image: public.ecr.aws/g6m3a0y9/gitvote-dbmigrator + - name: gitvote + image: public.ecr.aws/g6m3a0y9/gitvote + artifacthub.io/links: | + - name: source + url: https://github.com/cncf/gitvote + - name: support + url: https://github.com/cncf/gitvote/issues diff --git a/charts/gitvote/README.md b/charts/gitvote/README.md new file mode 100644 index 0000000..ecbe93b --- /dev/null +++ b/charts/gitvote/README.md @@ -0,0 +1,73 @@ +# GitVote + +[GitVote](https://gitvote.dev) is a GitHub application that allows holding a vote on issues and pull requests. + +## Introduction + +This chart bootstraps a GitVote deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. + +## Prerequisites + +Before installing this chart, you need to [setup a GitHub application](https://docs.github.com/en/apps/creating-github-apps/creating-github-apps/creating-a-github-app). The application requires the following permissions [to be set](https://docs.github.com/en/apps/maintaining-github-apps/editing-a-github-apps-permissions): + +Repository: + +- **Checks**: *read/write* +- **Contents**: *read* +- **Issues**: *read/write* +- **Metadata**: *read* +- **Pull requests**: *read/write* + +Organization: + +- **Members**: *read* + +In addition to those permissions, it must also be subscribed to the following events: + +- *Issue Comment* +- *Issues* +- *Pull Request* + +GitVote expects GitHub events to be sent to the `/api/events` endpoint. In the GitHub application, please enable `webhook` and set the target URL to your exposed endpoint (ie: ). You will need to define a random secret for the webhook (you can use the following command to do it: `openssl rand -hex 32`). Please note your webhook secret, as well as the GitHub application ID and private key, as you'll need them in the next step when installing the chart. + +Once your GitHub application is ready and GitVote has been deployed, you can install it in the organizations or repositories you need. + +## Installing the chart + +Create a values file (`my-values.yaml`) that includes the configuration values required from your GitHub application: + +```yaml +gitvote: + github: + appID: 123456 # Replace with your GitHub app ID + appPrivateKey: |- + -----BEGIN RSA PRIVATE KEY----- + ... + YOUR_APP_PRIVATE_KEY + ... + -----END RSA PRIVATE KEY----- + webhookSecret: "your-webhook-secret" +``` + +To install the chart with the release name `my-gitvote` run: + +```bash +$ helm repo add gitvote https://cncf.github.io/gitvote/ +$ helm install --values my-values.yaml my-gitvote gitvote/gitvote +``` + +The command above deploys GitVote on the Kubernetes cluster using the default configuration values and the GitHub application configuration provided. Please see the [chart's default values file](https://github.com/cncf/gitvote/blob/main/charts/gitvote/values.yaml) for a list of all the configurable parameters of the chart and their default values. + +## Uninstalling the chart + +To uninstall the `my-gitvote` deployment run: + +```bash +$ helm uninstall my-gitvote +``` + +This command removes all the Kubernetes components associated with the chart and deletes the release. + +## How GitVote works + +For more information about how GitVote works from a user's perspective please see the [repository's README file](https://github.com/cncf/gitvote#readme). diff --git a/charts/gitvote/values.yaml b/charts/gitvote/values.yaml index d66249a..8968f6d 100644 --- a/charts/gitvote/values.yaml +++ b/charts/gitvote/values.yaml @@ -40,28 +40,8 @@ gitvote: # GitHub configuration # - # The app require the following permissions: - # - Repository permissions: - # - Checks: read/write - # - Contents: read - # - Issues: read/write - # - Metadata: read - # - Pull requests: read/write - # - Organization - # - Members: read - # - # Subscribe to events: - # - Issue Comment - # - Issues - # - Pull Request - # - # GitVote can process GitHub webhooks data sent to /api/events. - # In the GitHub app, enable webhook and set the target URL to your exposed - # endpoint, ie: https://example.com/api/events - # Define a random webhook secret, you can use the following command to - # generate one: openssl rand -hex 32 - # After creating the app, download the private key an fill-up the values - # below: + # For more information about the permissions and events required please see + # the chart's readme file. github: # GitHub application ID appID: null