Compare commits
40 commits
d6c10ab629
...
ed67f5ecce
Author | SHA1 | Date | |
---|---|---|---|
ed67f5ecce | |||
fda06a8820 | |||
27a50c5dc3 | |||
625592487c | |||
1aee5b1566 | |||
e5263e2149 | |||
e4d3318d9d | |||
a4a45e5dc6 | |||
93018e5b70 | |||
4136766588 | |||
d4073a9b2d | |||
069772640d | |||
7af7a1a86d | |||
37f1fd426f | |||
22990ba13d | |||
39e46b1aaf | |||
6e04a2e568 | |||
2a0d8b34e2 | |||
83f5109f1d | |||
0f65bd87a7 | |||
9534e273b5 | |||
6945449106 | |||
76a4966d62 | |||
355767dbf3 | |||
5f0371ea5e | |||
f00108f53b | |||
6353dfae5b | |||
975513d0b9 | |||
c83bf98e7b | |||
975159ad41 | |||
8a4793a671 | |||
a9a1d37c66 | |||
388a550697 | |||
07edb85915 | |||
332039d9c6 | |||
9fcd641749 | |||
56a73c3042 | |||
8b52e1e31f | |||
7844613116 | |||
7a9a5e4dfb |
30 changed files with 420 additions and 20 deletions
.archive/default/matter-server
.renovate
.taskfiles/flux
kubernetes
apps
ai/open-webui/app
anime
radarr/app
sonarr/app
ci-runners/forgejo/app
coder/coder/app
default
autobrr/app
linkwarden/app
pterodactyl/app
radarr/app
redlib/app
sonarr/app
stirling-pdf/app
kube-system/reloader/app
observability/grafana/app
qbittorrent
security/external-secrets/app
flux/repositories/oci
21
.archive/default/matter-server/app/gatus.yaml
Normal file
21
.archive/default/matter-server/app/gatus.yaml
Normal file
|
@ -0,0 +1,21 @@
|
|||
---
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: matter-server-gatus-ep
|
||||
labels:
|
||||
gatus.io/enabled: "true"
|
||||
data:
|
||||
config.yaml: |
|
||||
endpoints:
|
||||
- name: matter-server
|
||||
group: infrastructure
|
||||
url: ws://matter-server.default.svc.cluster.local:5580
|
||||
interval: 1m
|
||||
ui:
|
||||
hide-url: true
|
||||
hide-hostname: true
|
||||
conditions:
|
||||
- "[CONNECTED] == true"
|
||||
alerts:
|
||||
- type: pushover
|
80
.archive/default/matter-server/app/helmrelease.yaml
Normal file
80
.archive/default/matter-server/app/helmrelease.yaml
Normal file
|
@ -0,0 +1,80 @@
|
|||
---
|
||||
# yaml-language-server: $schema=https://raw.githubusercontent.com/bjw-s/helm-charts/main/charts/other/app-template/schemas/helmrelease-helm-v2.schema.json
|
||||
apiVersion: helm.toolkit.fluxcd.io/v2
|
||||
kind: HelmRelease
|
||||
metadata:
|
||||
name: &app matter-server
|
||||
spec:
|
||||
interval: 30m
|
||||
chart:
|
||||
spec:
|
||||
chart: app-template
|
||||
version: 3.5.1
|
||||
sourceRef:
|
||||
kind: HelmRepository
|
||||
name: bjw-s
|
||||
namespace: flux-system
|
||||
install:
|
||||
remediation:
|
||||
retries: 3
|
||||
upgrade:
|
||||
cleanupOnFail: true
|
||||
remediation:
|
||||
retries: 3
|
||||
strategy: rollback
|
||||
values:
|
||||
controllers:
|
||||
matter-server:
|
||||
annotations:
|
||||
reloader.stakater.com/auto: "true"
|
||||
containers:
|
||||
app:
|
||||
image:
|
||||
repository: ghcr.io/home-assistant-libs/python-matter-server
|
||||
tag: 6.6.1
|
||||
pullPolicy: IfNotPresent
|
||||
env:
|
||||
TZ: "America/Chicago"
|
||||
MATTER_SERVER__INSTANCE_NAME: *app
|
||||
MATTER_SERVER__PORT: &port 5580
|
||||
MATTER_SERVER__APPLICATION_URL: &host matter.jahanson.tech
|
||||
MATTER_SERVER__LOG_LEVEL: debug
|
||||
resources:
|
||||
requests:
|
||||
memory: "100Mi"
|
||||
limits:
|
||||
memory: "300Mi"
|
||||
defaultPodOptions:
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
runAsUser: 568
|
||||
runAsGroup: 568
|
||||
fsGroup: 568
|
||||
fsGroupChangePolicy: OnRootMismatch
|
||||
seccompProfile: { type: RuntimeDefault }
|
||||
service:
|
||||
app:
|
||||
controller: matter-server
|
||||
type: LoadBalancer
|
||||
annotations:
|
||||
external-dns.alpha.kubernetes.io/hostname: *host
|
||||
io.cilium/lb-ipam-ips: 10.1.1.40
|
||||
ports:
|
||||
http:
|
||||
port: *port
|
||||
ingress:
|
||||
app:
|
||||
className: internal-nginx
|
||||
hosts:
|
||||
- host: *host
|
||||
paths:
|
||||
- path: /
|
||||
service:
|
||||
identifier: app
|
||||
port: *port
|
||||
tls:
|
||||
- hosts:
|
||||
- *host
|
||||
persistence:
|
||||
data:
|
||||
existingClaim: *app
|
8
.archive/default/matter-server/app/kustomization.yaml
Normal file
8
.archive/default/matter-server/app/kustomization.yaml
Normal file
|
@ -0,0 +1,8 @@
|
|||
---
|
||||
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- ./gatus.yaml
|
||||
- ./helmrelease.yaml
|
||||
- ../../../../templates/volsync
|
24
.archive/default/matter-server/ks.yaml
Normal file
24
.archive/default/matter-server/ks.yaml
Normal file
|
@ -0,0 +1,24 @@
|
|||
---
|
||||
# yaml-language-server: $schema=https://ks.hsn.dev/kustomize.toolkit.fluxcd.io/kustomization_v1.json
|
||||
apiVersion: kustomize.toolkit.fluxcd.io/v1
|
||||
kind: Kustomization
|
||||
metadata:
|
||||
name: &app matter-server
|
||||
namespace: flux-system
|
||||
spec:
|
||||
targetNamespace: default
|
||||
commonMetadata:
|
||||
labels:
|
||||
app.kubernetes.io/name: *app
|
||||
path: ./kubernetes/apps/default/matter-server/app
|
||||
prune: true
|
||||
sourceRef:
|
||||
kind: GitRepository
|
||||
name: theshire
|
||||
wait: false # no flux ks dependents
|
||||
interval: 30m
|
||||
timeout: 5m
|
||||
postBuild:
|
||||
substitute:
|
||||
APP: *app
|
||||
VOLSYNC_CAPACITY: 1Gi
|
|
@ -4,7 +4,7 @@
|
|||
{
|
||||
"description": ["Loose versioning for non-semver packages"],
|
||||
"matchDatasources": ["docker"],
|
||||
"matchPackagePatterns": ["cross-seed", "plex"],
|
||||
"matchPackagePatterns": ["plex"],
|
||||
"versioning": "loose"
|
||||
},
|
||||
{
|
||||
|
|
|
@ -18,6 +18,20 @@ tasks:
|
|||
| xargs -P 4 -L 1 bash -c \
|
||||
'kubectl -n $0 annotate kustomization/$1 reconcile.fluxcd.io/requestedAt="$(date +%s)" --field-manager=flux-client-side-apply --overwrite'
|
||||
|
||||
ks-suspend:
|
||||
desc: Suspend all Flux Kustomizations
|
||||
cmds:
|
||||
- |
|
||||
flux get kustomizations --all-namespaces --no-header | awk '{print $1, $2}' \
|
||||
| xargs -L 1 bash -c 'flux -n $0 suspend kustomization $1'
|
||||
|
||||
ks-resume:
|
||||
desc: Resume all Flux Kustomizations
|
||||
cmds:
|
||||
- |
|
||||
flux get kustomizations --all-namespaces --no-header | awk '{print $1, $2}' \
|
||||
| xargs -L 1 bash -c 'flux -n $0 resume kustomization $1'
|
||||
|
||||
hr-sync:
|
||||
desc: Sync all Flux HelmReleases
|
||||
cmds:
|
||||
|
|
|
@ -33,7 +33,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/open-webui/open-webui
|
||||
tag: v0.4.5
|
||||
tag: v0.4.7
|
||||
env:
|
||||
- name: OLLAMA_BASE_URL
|
||||
value: http://10.1.1.61:11434
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/onedr0p/radarr-develop
|
||||
tag: 5.15.1.9463
|
||||
tag: 5.16.0.9485
|
||||
env:
|
||||
RADARR__APP__INSTANCENAME: Radarr-Anime
|
||||
RADARR__APP__THEME: dark
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/onedr0p/sonarr-develop
|
||||
tag: 4.0.11.2697
|
||||
tag: 4.0.11.2724
|
||||
env:
|
||||
SONARR__APP__INSTANCENAME: Sonarr-Anime
|
||||
SONARR__APP__THEME: dark
|
||||
|
@ -117,3 +117,14 @@ spec:
|
|||
path: /moria/media/
|
||||
globalMounts:
|
||||
- path: /data/moria-media
|
||||
scripts:
|
||||
type: configMap
|
||||
name: sonarr-configmap
|
||||
defaultMode: 0775
|
||||
globalMounts:
|
||||
- path: /scripts/pushover-notify.sh
|
||||
subPath: pushover-notify.sh
|
||||
readOnly: true
|
||||
- path: /scripts/refresh-series.sh
|
||||
subPath: refresh-series.sh
|
||||
readOnly: true
|
||||
|
|
|
@ -6,3 +6,12 @@ resources:
|
|||
- ./externalsecret.yaml
|
||||
- ./helmrelease.yaml
|
||||
- ../../../../templates/volsync
|
||||
configMapGenerator:
|
||||
- name: sonarr-configmap
|
||||
files:
|
||||
- pushover-notify.sh=./resources/pushover-notify.sh
|
||||
- refresh-series.sh=./resources/refresh-series.sh
|
||||
generatorOptions:
|
||||
disableNameSuffixHash: true
|
||||
annotations:
|
||||
kustomize.toolkit.fluxcd.io/substitute: disabled
|
||||
|
|
|
@ -0,0 +1,85 @@
|
|||
#!/usr/bin/env bash
|
||||
# shellcheck disable=SC2154
|
||||
set -euo pipefail
|
||||
|
||||
# User defined variables for pushover
|
||||
PUSHOVER_USER_KEY="${PUSHOVER_USER_KEY:-required}"
|
||||
PUSHOVER_TOKEN="${PUSHOVER_TOKEN:-required}"
|
||||
PUSHOVER_PRIORITY="${PUSHOVER_PRIORITY:-"-2"}"
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "Test" ]]; then
|
||||
PUSHOVER_PRIORITY="1"
|
||||
printf -v PUSHOVER_TITLE \
|
||||
"Test Notification"
|
||||
printf -v PUSHOVER_MESSAGE \
|
||||
"Howdy this is a test notification from %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
printf -v PUSHOVER_URL \
|
||||
"%s" \
|
||||
"${sonarr_applicationurl:-localhost}"
|
||||
printf -v PUSHOVER_URL_TITLE \
|
||||
"Open %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
fi
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "Download" ]]; then
|
||||
printf -v PUSHOVER_TITLE \
|
||||
"Episode %s" \
|
||||
"$( [[ "${sonarr_isupgrade}" == "True" ]] && echo "Upgraded" || echo "Downloaded" )"
|
||||
printf -v PUSHOVER_MESSAGE \
|
||||
"<b>%s (S%02dE%02d)</b><small>\n%s</small><small>\n\n<b>Quality:</b> %s</small><small>\n<b>Client:</b> %s</small>" \
|
||||
"${sonarr_series_title}" \
|
||||
"${sonarr_episodefile_seasonnumber}" \
|
||||
"${sonarr_episodefile_episodenumbers}" \
|
||||
"${sonarr_episodefile_episodetitles}" \
|
||||
"${sonarr_episodefile_quality:-Unknown}" \
|
||||
"${sonarr_download_client:-Unknown}"
|
||||
printf -v PUSHOVER_URL \
|
||||
"%s/series/%s" \
|
||||
"${sonarr_applicationurl:-localhost}" \
|
||||
"${sonarr_series_titleslug}"
|
||||
printf -v PUSHOVER_URL_TITLE \
|
||||
"View series in %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
fi
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "ManualInteractionRequired" ]]; then
|
||||
PUSHOVER_PRIORITY="1"
|
||||
printf -v PUSHOVER_TITLE \
|
||||
"Episode import requires intervention"
|
||||
printf -v PUSHOVER_MESSAGE \
|
||||
"<b>%s</b><small>\n<b>Client:</b> %s</small>" \
|
||||
"${sonarr_series_title}" \
|
||||
"${sonarr_download_client:-Unknown}"
|
||||
printf -v PUSHOVER_URL \
|
||||
"%s/activity/queue" \
|
||||
"${sonarr_applicationurl:-localhost}"
|
||||
printf -v PUSHOVER_URL_TITLE \
|
||||
"View queue in %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
fi
|
||||
|
||||
json_data=$(jo \
|
||||
token="${PUSHOVER_TOKEN}" \
|
||||
user="${PUSHOVER_USER_KEY}" \
|
||||
title="${PUSHOVER_TITLE}" \
|
||||
message="${PUSHOVER_MESSAGE}" \
|
||||
url="${PUSHOVER_URL}" \
|
||||
url_title="${PUSHOVER_URL_TITLE}" \
|
||||
priority="${PUSHOVER_PRIORITY}" \
|
||||
html="1"
|
||||
)
|
||||
|
||||
status_code=$(curl \
|
||||
--silent \
|
||||
--write-out "%{http_code}" \
|
||||
--output /dev/null \
|
||||
--request POST \
|
||||
--header "Content-Type: application/json" \
|
||||
--data-binary "${json_data}" \
|
||||
"https://api.pushover.net/1/messages.json" \
|
||||
)
|
||||
|
||||
printf "pushover notification returned with HTTP status code %s and payload: %s\n" \
|
||||
"${status_code}" \
|
||||
"$(echo "${json_data}" | jq --compact-output)" >&2
|
21
kubernetes/apps/anime/sonarr/app/resources/refresh-series.sh
Normal file
21
kubernetes/apps/anime/sonarr/app/resources/refresh-series.sh
Normal file
|
@ -0,0 +1,21 @@
|
|||
#!/usr/bin/env bash
|
||||
# shellcheck disable=SC2154
|
||||
set -euo pipefail
|
||||
|
||||
CURL_CMD=(curl -fsSL --header "X-Api-Key: ${SONARR__AUTH__APIKEY:-}")
|
||||
SONARR_API_URL="http://localhost:${SONARR__SERVER__PORT:-}/api/v3"
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "Grab" ]]; then
|
||||
tba=$("${CURL_CMD[@]}" "${SONARR_API_URL}/episode?seriesId=${sonarr_series_id:-}" | jq --raw-output '
|
||||
[.[] | select((.title == "TBA") or (.title == "TBD"))] | length
|
||||
')
|
||||
|
||||
if (( tba > 0 )); then
|
||||
echo "INFO: Refreshing series ${sonarr_series_id:-} due to TBA/TBD episodes found"
|
||||
"${CURL_CMD[@]}" \
|
||||
--request POST \
|
||||
--header "Content-Type: application/json" \
|
||||
--data-binary '{"name": "RefreshSeries", "seriesId": '"${sonarr_series_id:-}"'}' \
|
||||
"${SONARR_API_URL}/command" &>/dev/null
|
||||
fi
|
||||
fi
|
|
@ -30,7 +30,7 @@ spec:
|
|||
runner-register:
|
||||
image:
|
||||
repository: code.forgejo.org/forgejo/runner
|
||||
tag: 5.0.2
|
||||
tag: 5.0.3
|
||||
command:
|
||||
- "forgejo-runner"
|
||||
- "register"
|
||||
|
@ -72,7 +72,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: code.forgejo.org/forgejo/runner
|
||||
tag: 5.0.2
|
||||
tag: 5.0.3
|
||||
command:
|
||||
- "sh"
|
||||
- "-c"
|
||||
|
|
|
@ -9,7 +9,7 @@ spec:
|
|||
chart:
|
||||
spec:
|
||||
chart: coder
|
||||
version: 2.17.2
|
||||
version: 2.18.0
|
||||
sourceRef:
|
||||
kind: HelmRepository
|
||||
name: coder
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/autobrr/autobrr
|
||||
tag: v1.51.1@sha256:747c682d8d59e72a202ee4239bafbd7cfa10b0fc3a6220b61446de73dbd0c956
|
||||
tag: v1.52.0@sha256:329307d54fcfc8a79536a2619b5b78a834706dd97ea34c50180f52591fe5ce01
|
||||
env:
|
||||
AUTOBRR__CHECK_FOR_UPDATES: "false"
|
||||
AUTOBRR__HOST: 0.0.0.0
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/linkwarden/linkwarden
|
||||
tag: v2.8.3@sha256:7f80a03d688c3e5d9ec6b34f5b65cd861ff8c9eb08d12932dc8fc7482991f238
|
||||
tag: v2.8.4@sha256:8a8e6323508f97ddaa863281b9ff52949fc153eea1ec07cb84539436371caf28
|
||||
env:
|
||||
TIMEZONE: "America/Chicago"
|
||||
NEXTAUTH_URL: "https://{{ .Release.Name }}.jahanson.tech/api/v1/auth"
|
||||
|
|
|
@ -4,7 +4,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
|
|||
kind: Kustomization
|
||||
resources:
|
||||
- ../../../../templates/volsync
|
||||
- ../../../../templates/gatus/external
|
||||
# - ../../../../templates/gatus/external
|
||||
- ./externalsecret.yaml
|
||||
# - ./helmrelease.yaml
|
||||
- ./mariadb.yaml
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/onedr0p/radarr-develop
|
||||
tag: 5.15.1.9463
|
||||
tag: 5.16.0.9485
|
||||
env:
|
||||
RADARR__APP__INSTANCENAME: Radarr
|
||||
RADARR__APP__THEME: dark
|
||||
|
|
|
@ -38,7 +38,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: quay.io/redlib/redlib
|
||||
tag: latest@sha256:1f120c85fc33bdac67c97d5d1a6c84a920be40742fbf311c970ab2749a435778
|
||||
tag: latest@sha256:d04e722091fe17424425499882a548507a70654f37aaf8cbc71081ef29b7b341
|
||||
env:
|
||||
REDLIB_DEFAULT_SHOW_NSFW: on
|
||||
REDLIB_DEFAULT_WIDE: on
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/onedr0p/sonarr-develop
|
||||
tag: 4.0.11.2697
|
||||
tag: 4.0.11.2724
|
||||
env:
|
||||
SONARR__APP__INSTANCENAME: Sonarr
|
||||
SONARR__APP__THEME: dark
|
||||
|
@ -115,3 +115,15 @@ spec:
|
|||
path: /moria/media/
|
||||
globalMounts:
|
||||
- path: /data/moria-media
|
||||
scripts:
|
||||
type: configMap
|
||||
name: sonarr-configmap
|
||||
defaultMode: 0775
|
||||
globalMounts:
|
||||
- path: /scripts/pushover-notify.sh
|
||||
subPath: pushover-notify.sh
|
||||
readOnly: true
|
||||
- path: /scripts/refresh-series.sh
|
||||
subPath: refresh-series.sh
|
||||
readOnly: true
|
||||
|
||||
|
|
|
@ -6,3 +6,12 @@ resources:
|
|||
- ./externalsecret.yaml
|
||||
- ./helmrelease.yaml
|
||||
- ../../../../templates/volsync
|
||||
configMapGenerator:
|
||||
- name: sonarr-configmap
|
||||
files:
|
||||
- pushover-notify.sh=./resources/pushover-notify.sh
|
||||
- refresh-series.sh=./resources/refresh-series.sh
|
||||
generatorOptions:
|
||||
disableNameSuffixHash: true
|
||||
annotations:
|
||||
kustomize.toolkit.fluxcd.io/substitute: disabled
|
||||
|
|
|
@ -0,0 +1,85 @@
|
|||
#!/usr/bin/env bash
|
||||
# shellcheck disable=SC2154
|
||||
set -euo pipefail
|
||||
|
||||
# User defined variables for pushover
|
||||
PUSHOVER_USER_KEY="${PUSHOVER_USER_KEY:-required}"
|
||||
PUSHOVER_TOKEN="${PUSHOVER_TOKEN:-required}"
|
||||
PUSHOVER_PRIORITY="${PUSHOVER_PRIORITY:-"-2"}"
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "Test" ]]; then
|
||||
PUSHOVER_PRIORITY="1"
|
||||
printf -v PUSHOVER_TITLE \
|
||||
"Test Notification"
|
||||
printf -v PUSHOVER_MESSAGE \
|
||||
"Howdy this is a test notification from %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
printf -v PUSHOVER_URL \
|
||||
"%s" \
|
||||
"${sonarr_applicationurl:-localhost}"
|
||||
printf -v PUSHOVER_URL_TITLE \
|
||||
"Open %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
fi
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "Download" ]]; then
|
||||
printf -v PUSHOVER_TITLE \
|
||||
"Episode %s" \
|
||||
"$( [[ "${sonarr_isupgrade}" == "True" ]] && echo "Upgraded" || echo "Downloaded" )"
|
||||
printf -v PUSHOVER_MESSAGE \
|
||||
"<b>%s (S%02dE%02d)</b><small>\n%s</small><small>\n\n<b>Quality:</b> %s</small><small>\n<b>Client:</b> %s</small>" \
|
||||
"${sonarr_series_title}" \
|
||||
"${sonarr_episodefile_seasonnumber}" \
|
||||
"${sonarr_episodefile_episodenumbers}" \
|
||||
"${sonarr_episodefile_episodetitles}" \
|
||||
"${sonarr_episodefile_quality:-Unknown}" \
|
||||
"${sonarr_download_client:-Unknown}"
|
||||
printf -v PUSHOVER_URL \
|
||||
"%s/series/%s" \
|
||||
"${sonarr_applicationurl:-localhost}" \
|
||||
"${sonarr_series_titleslug}"
|
||||
printf -v PUSHOVER_URL_TITLE \
|
||||
"View series in %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
fi
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "ManualInteractionRequired" ]]; then
|
||||
PUSHOVER_PRIORITY="1"
|
||||
printf -v PUSHOVER_TITLE \
|
||||
"Episode import requires intervention"
|
||||
printf -v PUSHOVER_MESSAGE \
|
||||
"<b>%s</b><small>\n<b>Client:</b> %s</small>" \
|
||||
"${sonarr_series_title}" \
|
||||
"${sonarr_download_client:-Unknown}"
|
||||
printf -v PUSHOVER_URL \
|
||||
"%s/activity/queue" \
|
||||
"${sonarr_applicationurl:-localhost}"
|
||||
printf -v PUSHOVER_URL_TITLE \
|
||||
"View queue in %s" \
|
||||
"${sonarr_instancename:-Sonarr}"
|
||||
fi
|
||||
|
||||
json_data=$(jo \
|
||||
token="${PUSHOVER_TOKEN}" \
|
||||
user="${PUSHOVER_USER_KEY}" \
|
||||
title="${PUSHOVER_TITLE}" \
|
||||
message="${PUSHOVER_MESSAGE}" \
|
||||
url="${PUSHOVER_URL}" \
|
||||
url_title="${PUSHOVER_URL_TITLE}" \
|
||||
priority="${PUSHOVER_PRIORITY}" \
|
||||
html="1"
|
||||
)
|
||||
|
||||
status_code=$(curl \
|
||||
--silent \
|
||||
--write-out "%{http_code}" \
|
||||
--output /dev/null \
|
||||
--request POST \
|
||||
--header "Content-Type: application/json" \
|
||||
--data-binary "${json_data}" \
|
||||
"https://api.pushover.net/1/messages.json" \
|
||||
)
|
||||
|
||||
printf "pushover notification returned with HTTP status code %s and payload: %s\n" \
|
||||
"${status_code}" \
|
||||
"$(echo "${json_data}" | jq --compact-output)" >&2
|
|
@ -0,0 +1,21 @@
|
|||
#!/usr/bin/env bash
|
||||
# shellcheck disable=SC2154
|
||||
set -euo pipefail
|
||||
|
||||
CURL_CMD=(curl -fsSL --header "X-Api-Key: ${SONARR__AUTH__APIKEY:-}")
|
||||
SONARR_API_URL="http://localhost:${SONARR__SERVER__PORT:-}/api/v3"
|
||||
|
||||
if [[ "${sonarr_eventtype:-}" == "Grab" ]]; then
|
||||
tba=$("${CURL_CMD[@]}" "${SONARR_API_URL}/episode?seriesId=${sonarr_series_id:-}" | jq --raw-output '
|
||||
[.[] | select((.title == "TBA") or (.title == "TBD"))] | length
|
||||
')
|
||||
|
||||
if (( tba > 0 )); then
|
||||
echo "INFO: Refreshing series ${sonarr_series_id:-} due to TBA/TBD episodes found"
|
||||
"${CURL_CMD[@]}" \
|
||||
--request POST \
|
||||
--header "Content-Type: application/json" \
|
||||
--data-binary '{"name": "RefreshSeries", "seriesId": '"${sonarr_series_id:-}"'}' \
|
||||
"${SONARR_API_URL}/command" &>/dev/null
|
||||
fi
|
||||
fi
|
|
@ -31,7 +31,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/stirling-tools/s-pdf
|
||||
tag: 0.34.0@sha256:42ceaa84712f9271ca4af1c4d892899996424cbc5378f7dd168828091657c0f0
|
||||
tag: 0.35.0@sha256:cb8a830837050490ea2a193e227299a0cdc147f97cd76873a8775e0bc3ca9b10
|
||||
pullPolicy: IfNotPresent
|
||||
env:
|
||||
TZ: America/Chicago
|
||||
|
|
|
@ -10,7 +10,7 @@ spec:
|
|||
chart:
|
||||
spec:
|
||||
chart: reloader
|
||||
version: 1.1.0
|
||||
version: 1.2.0
|
||||
sourceRef:
|
||||
kind: HelmRepository
|
||||
name: stakater
|
||||
|
|
|
@ -239,7 +239,7 @@ spec:
|
|||
prometheus:
|
||||
# renovate: depName="Prometheus"
|
||||
gnetId: 19105
|
||||
revision: 5
|
||||
revision: 6
|
||||
datasource: Prometheus
|
||||
victoria-agent:
|
||||
# renovate: depName="VictoriaMetrics - vmagent"
|
||||
|
|
|
@ -35,7 +35,7 @@ spec:
|
|||
app:
|
||||
image:
|
||||
repository: ghcr.io/cross-seed/cross-seed
|
||||
tag: 6.1.0@sha256:91fbb2a6a411b7d63cccabffb5f623e6931579d2fd652512b6a3df0a9ba97066
|
||||
tag: 6.1.1@sha256:5cb54b46a614f362c0332a91e5754d6998d45ae27ccc2c77b04b1a3493816331
|
||||
env:
|
||||
TZ: America/Chicago
|
||||
args: ["daemon"]
|
||||
|
|
|
@ -39,7 +39,7 @@ spec:
|
|||
tagging: &container
|
||||
image:
|
||||
repository: ghcr.io/buroa/qbtools
|
||||
tag: v0.19.9@sha256:f5405e3c00256d7911d2abb839084a5147c108586adb281e97587cf93729c89b
|
||||
tag: v0.19.10@sha256:fc9c2fd65a454d39084d3b7ea802c92dba4032fb0b4eaadf6a684fdf740b8c17
|
||||
env:
|
||||
TZ: *timeZone
|
||||
POD_NAMESPACE:
|
||||
|
|
|
@ -10,7 +10,7 @@ spec:
|
|||
chart:
|
||||
spec:
|
||||
chart: external-secrets
|
||||
version: 0.10.7
|
||||
version: 0.11.0
|
||||
interval: 30m
|
||||
sourceRef:
|
||||
kind: HelmRepository
|
||||
|
|
|
@ -12,4 +12,4 @@ spec:
|
|||
operation: copy
|
||||
url: oci://ghcr.io/grafana/helm-charts/grafana
|
||||
ref:
|
||||
tag: 8.6.3
|
||||
tag: 8.6.4
|
||||
|
|
Reference in a new issue