Update scarrs/Upgrade-Sonarr.sh
This commit is contained in:
parent
4751d34c0c
commit
670a7dd2a5
1 changed files with 3 additions and 3 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
system=sonarr
|
system="sonarr"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -33,7 +33,7 @@ CreateContainer () {
|
||||||
|
|
||||||
GetNewVer () {
|
GetNewVer () {
|
||||||
serv="$1"
|
serv="$1"
|
||||||
json="$(curl https://api.linuxserver.io/api/v1/images | jq .data.repositories.linuxserver[] | select(.name==$serv))"
|
json="$(curl https://api.linuxserver.io/api/v1/images | jq ".data.repositories.linuxserver[] | select(.name==$serv)")"
|
||||||
ver="$(echo $json | jq .version | awk -F'"' '{print $2}' | awk -F'.' '{print $1 "." $2 "." $3}')"
|
ver="$(echo $json | jq .version | awk -F'"' '{print $2}' | awk -F'.' '{print $1 "." $2 "." $3}')"
|
||||||
echo $ver
|
echo $ver
|
||||||
}
|
}
|
||||||
|
|
@ -41,7 +41,7 @@ echo $ver
|
||||||
GetOldVer () {
|
GetOldVer () {
|
||||||
serv=$1
|
serv=$1
|
||||||
currentPod=$(podman ps | grep $serv | awk '{print $NF}')
|
currentPod=$(podman ps | grep $serv | awk '{print $NF}')
|
||||||
echo currentPod
|
echo $currentPod
|
||||||
}
|
}
|
||||||
|
|
||||||
RemoveOldContainer () {
|
RemoveOldContainer () {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue