Skip to content

Commit

Permalink
Merge pull request #74 from homeylab/tdarr-exporter-1.1.3
Browse files Browse the repository at this point in the history
add api key options for tdarr-exporter
  • Loading branch information
pchang388 authored Aug 8, 2024
2 parents a84cc6e + 36799ed commit 38800f9
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 2 deletions.
4 changes: 2 additions & 2 deletions charts/tdarr-exporter/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 1.1.2
version: 1.1.3

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "1.2.0"
appVersion: "1.3.0"
2 changes: 2 additions & 0 deletions charts/tdarr-exporter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ For a full list of options, see `values.yaml` file.
| --------------------- | ----------------------------------------------------------------------------------------------------- | ------------------- |
| `metrics` | By default `podAnnotations` are enabled. Set `serviceMonitor.enabled` to `true` to instead use `serviceMonitors`. | This section allows users to set configuration for Prometheus `podAnnotations`, `serviceMonitors`, etc. See `values.yaml` section for more details on what can be customized. |
| `settings.config.url` | `NONE` | This is a required property and must be provided. If no protocol is provided (`http/https`), defaults to using `https`. Examples: `tdarr.example.com`, `http://tdarr.example.com`. |
| `settings.config.apiKey` | If `settings.config.existingSecret` is not supplied, provide `apiKey` for the Tdarr instance directly. If no auth required, leave blank. | `""` |
| `settings.config.existingSecret` | Provide an existing secret and the `key` within the secret data to use for the `apiKey` of the Tdarr instance. | `{}` |
| `settings.config.verify_ssl` | `true` | If set to `false`, the exporter will not verify the SSL certificate of the tdarr instance. |
| `settings.config.log_level` | `info` | Log level to use: `debug`, `info`, `warn`, `error`. |

Expand Down
10 changes: 10 additions & 0 deletions charts/tdarr-exporter/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,16 @@ spec:
env:
- name: TDARR_URL
value: {{ .Values.settings.config.url | quote }}
{{- if $val.existingSecret.name }}
- name: TDARR_API_KEY
valueFrom:
secretKeyRef:
name: {{ $val.existingSecret.name }}
key: {{ $val.existingSecret.secretKey }}
{{- else if $val.apiKey }}
- name: TDARR_API_KEY
value: {{ $val.apiKey | quote }}
{{- end }}
- name: VERIFY_SSL
value: {{ .Values.settings.config.verify_ssl | quote }}
- name: LOG_LEVEL
Expand Down
9 changes: 9 additions & 0 deletions charts/tdarr-exporter/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,15 @@ settings:
# If no protocol is provided (http/https), defaults to using https.
# Examples: `tdarr.example.com`, `http://tdarr.example.com`
url: ""
# if auth is not required, do not provide any `secretKey` or `apiKey`
existingSecret:
# name of secret
name: ""
# name of key within secret to use
# example: "tdarr_api_key"
secretKey: ""
# ignored if `existingSecret` is used
apiKey: ""
# `verify_ssl` - This is an optional property and defaults to `true`.
# If set to `false`, the exporter will not verify the SSL certificate of the tdarr instance.
verify_ssl: true
Expand Down

0 comments on commit 38800f9

Please sign in to comment.