Skip to content

Commit

Permalink
DO NOT MERGE: add Sentry to SIA
Browse files Browse the repository at this point in the history
  • Loading branch information
dhirving committed Dec 3, 2024
1 parent bfd37fa commit 62814be
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 0 deletions.
1 change: 1 addition & 0 deletions applications/sia/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Simple Image Access (SIA) IVOA Service using Butler
| affinity | object | `{}` | Affinity rules for the sia deployment pod |
| config.butlerDataCollections | list | `[]` | List of data (Butler) Collections Expected attributes: `config`, `label`, `name`, `butler_type`, `repository` & `datalink_url` |
| config.directButlerEnabled | bool | `false` | Whether direct butler access is enabled |
| config.enableSentry | bool | `false` | True to enable capture of trace and other diagnostics to Sentry.io. |
| config.logLevel | string | `"INFO"` | Logging level |
| config.logProfile | string | `"production"` | Logging profile (`production` for JSON, `development` for human-friendly) |
| config.pathPrefix | string | `"/api/sia"` | URL path prefix |
Expand Down
7 changes: 7 additions & 0 deletions applications/sia/secrets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,10 @@ slack-webhook:
copy:
application: mobu
key: app-alert-webhook
"sentry-dsn":
description: >-
DSN URL where Sentry trace and error logging will be sent.
if: config.enableSentry
copy:
application: butler
key: "sentry-dsn"
11 changes: 11 additions & 0 deletions applications/sia/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,17 @@ spec:
- name: "GOOGLE_APPLICATION_CREDENTIALS"
value: "/tmp/secrets/butler-gcs-idf-creds.json"
{{- end }}
{{ if .Values.config.enableSentry }}
- name: SENTRY_DSN
valueFrom:
secretKeyRef:
name: "sia"
key: "sentry-dsn"
- name: SENTRY_RELEASE
value: {{ .Chart.Name }}@{{ .Chart.AppVersion }}
- name: SENTRY_ENVIRONMENT
value: {{ .Values.global.host }}
{{ end }}
{{- if .Values.config.directButlerEnabled }}
volumeMounts:
- name: "secrets"
Expand Down
2 changes: 2 additions & 0 deletions applications/sia/values-idfdev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ config:
butler_type: "REMOTE"
repository: "https://data-dev.lsst.cloud/api/butler/repo/dp02/butler.yaml"
datalink_url: "https://data-dev.lsst.cloud/api/datalink/links?ID=butler%3A//dp02/{id}"

enableSentry: true
3 changes: 3 additions & 0 deletions applications/sia/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ config:
# connection
pgUser: "rubin"

# -- True to enable capture of trace and other diagnostics to Sentry.io.
enableSentry: false


ingress:
# -- Additional annotations for the ingress rule
Expand Down

0 comments on commit 62814be

Please sign in to comment.