mirror of
https://github.com/mag37/dockcheck.git
synced 2026-04-17 18:07:46 +00:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e6ff634394 | ||
|
|
6444e18a4f | ||
|
|
14872b0471 | ||
|
|
07ad241e9f | ||
|
|
15ce226a0a | ||
|
|
cce5438aca |
@@ -18,6 +18,7 @@
|
||||
___
|
||||
## :bell: Changelog
|
||||
|
||||
- **v0.5.3**: Local image check changed (use imageId instead of name) and Gotify-template fixed (whale icon removed).
|
||||
- **v0.5.2.1**: Rewrite of dependency downloads, jq can be installed with package manager or static binary.
|
||||
- **v0.5.1**: DEPENDENCY WARNING: now requires **jq**. + Upstreaming changes from [sudo-kraken/podcheck](https://github.com/sudo-kraken/podcheck)
|
||||
- **v0.5.0**: Rewritten notify logic - all templates are adjusted and should be migrated!
|
||||
@@ -27,7 +28,6 @@ ___
|
||||
- Added Discord notify template.
|
||||
- Verbosity changed of `regctl`.
|
||||
- **v0.4.9**: Added a function to enrich the notify-message with release note URLs. See [Release notes addon](https://github.com/mag37/dockcheck#date-release-notes-addon-to-notifications)
|
||||
- **v0.4.8**: Rewrote prune logic to not prompt with options `-a|-y` or `-n`. Auto prune with `-p`.
|
||||
___
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
VERSION="v0.5.2.1"
|
||||
### ChangeNotes: DEPENDENCY REMINDER: now requires jq. UPDATE: Rewrite of dependency installer.
|
||||
VERSION="v0.5.3.0"
|
||||
### ChangeNotes: Bugfixes - local image check changed, Gotify-template fixed
|
||||
Github="https://github.com/mag37/dockcheck"
|
||||
RawUrl="https://raw.githubusercontent.com/mag37/dockcheck/main/dockcheck.sh"
|
||||
|
||||
@@ -284,8 +284,9 @@ for i in $(docker ps $Stopped --filter "name=$SearchName" --format '{{.Names}}')
|
||||
progress_bar "$RegCheckQue" "$ContCount"
|
||||
# Looping every item over the list of excluded names and skipping
|
||||
for e in "${Excludes[@]}" ; do [[ "$i" == "$e" ]] && continue 2 ; done
|
||||
ImageId=$(docker inspect "$i" --format='{{.Image}}')
|
||||
RepoUrl=$(docker inspect "$i" --format='{{.Config.Image}}')
|
||||
LocalHash=$(docker image inspect "$RepoUrl" --format '{{.RepoDigests}}')
|
||||
LocalHash=$(docker image inspect "$ImageId" --format '{{.RepoDigests}}')
|
||||
# Checking for errors while setting the variable
|
||||
if RegHash=$(${t_out} $regbin -v error image digest --list "$RepoUrl" 2>&1) ; then
|
||||
if [[ "$LocalHash" = *"$RegHash"* ]] ; then
|
||||
|
||||
@@ -49,4 +49,6 @@ Content-Transfer-Encoding: 7bit
|
||||
$MessageBody
|
||||
From $SenderName
|
||||
__EOF
|
||||
# This ensures DSM's container manager will also see the update
|
||||
/var/packages/ContainerManager/target/tool/image_upgradable_checker
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ send_notification() {
|
||||
|
||||
# Setting the MessageTitle and MessageBody variable here.
|
||||
MessageTitle="${FromHost} - updates available."
|
||||
printf -v MessageBody "🐋 Containers on $FromHost with updates available:\n$UpdToString"
|
||||
printf -v MessageBody "Containers on $FromHost with updates available:\n$UpdToString"
|
||||
|
||||
# Modify to fit your setup:
|
||||
GotifyToken="Your Gotify token here"
|
||||
@@ -24,6 +24,6 @@ send_notification() {
|
||||
-F "title=${MessageTitle}" \
|
||||
-F "message=${MessageBody}" \
|
||||
-F "priority=5" \
|
||||
-X POST "${GotifyUrl}" &> /dev/null
|
||||
-X POST "${GotifyUrl}" 1> /dev/null
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user