Skip to content

Commit

Permalink
feat(chart): allow Github App installation Id (#404)
Browse files Browse the repository at this point in the history
* feat(chart): allow Github App installation Id
* updated version
* updated schema
* updated docs
  • Loading branch information
bdellegrazie committed Jul 8, 2024
1 parent a72f86c commit 788d495
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion charts/atlantis/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: v1
appVersion: v0.28.3
description: A Helm chart for Atlantis https://www.runatlantis.io
name: atlantis
version: 5.3.0
version: 5.4.0
keywords:
- terraform
home: https://www.runatlantis.io
Expand Down
4 changes: 2 additions & 2 deletions charts/atlantis/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ extraManifests:
| gitconfig | string | `""` | When referencing Terraform modules in private repositories, it may be helpful (necessary?) to use redirection in a .gitconfig. Check values.yaml for examples. |
| gitconfigSecretName | string | `""` | If managing secrets outside the chart for the gitconfig, use this variable to reference the secret name |
| github | object | `{}` | If using GitHub, please enter your values as follows. The chart will perform the base64 encoding for values that are stored in secrets. The 'hostname' key is exclusive to GitHub Enterprise installations. Check values.yaml for examples. |
| githubApp | object | `{}` | If using a GitHub App, please enter your values as follows. The chart will perform the base64 encoding for you for values that are stored in secrets. Check values.yaml for examples. |
| githubApp | object | `{}` | If using a GitHub App, please enter your values as follows. The chart will perform the base64 encoding for you for values that are stored in secrets. installationId is necessary when there are multiple installs of the Github App. Check values.yaml for examples. |
| gitlab | object | `{}` | If using GitLab, please enter your values as follows. The 'hostname' key is exclusive to GitLab Enterprise installations. The chart will perform the base64 encoding for you for values that are stored in secrets. Check values.yaml for examples. |
| googleServiceAccountSecrets | list | `[]` | Optionally specify google service account credentials as Kubernetes secrets. If you are using the terraform google provider you can specify the credentials as "${file("/var/secrets/some-secret-name/key.json")}". Check values.yaml for examples. |
| hidePrevPlanComments | bool | `false` | Enables atlantis to hide previous plan comments. |
Expand Down Expand Up @@ -404,4 +404,4 @@ make unit-test-run-atlantis
```

----------------------------------------------
Autogenerated from chart metadata using [helm-docs v1.13.1](https://github.com/norwoodj/helm-docs/releases/v1.13.1)
Autogenerated from chart metadata using [helm-docs v1.14.0](https://github.com/norwoodj/helm-docs/releases/v1.14.0)
4 changes: 4 additions & 0 deletions charts/atlantis/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,10 @@ spec:
- name: ATLANTIS_GH_APP_ID
value: {{ .Values.githubApp.id | quote}}
{{- end }}
{{- if .Values.githubApp.installationId }}
- name: ATLANTIS_GH_APP_INSTALLATION_ID
value: {{ .Values.githubApp.installationId | quote}}
{{- end }}
{{- if .Values.githubApp.slug }}
- name: ATLANTIS_GH_APP_SLUG
value: {{ .Values.githubApp.slug | quote}}
Expand Down
7 changes: 7 additions & 0 deletions charts/atlantis/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,13 @@
],
"description": "GitHub app ID. If set, GitHub authentication will be performed as an [installation](https://developer.github.com/v3/apps/installations/)."
},
"installationId": {
"type": [
"integer",
"string"
],
"description": "GitHub app installationId. If set, GitHub authentication will be performed as an [installation](https://developer.github.com/v3/apps/installations/)."
},
"slug": {
"type": "string",
"description": "A slugged version of GitHub app name shown in pull requests comments, etc (not Atlantis App but something like atlantis-app). Atlantis uses the value of this parameter to identify the comments it has left on GitHub pull requests. This is used for functions such as `hidePrevPlanComments`."
Expand Down
2 changes: 2 additions & 0 deletions charts/atlantis/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,12 @@ github: {}

# -- If using a GitHub App, please enter your values as follows.
# The chart will perform the base64 encoding for you for values that are stored in secrets.
# installationId is necessary when there are multiple installs of the Github App.
# Check values.yaml for examples.
githubApp: {}
# githubApp:
# id: 123456
# installationId: 1
# slug: foo
# key: |
# -----BEGIN PRIVATE KEY-----
Expand Down

0 comments on commit 788d495

Please sign in to comment.