Replace manual jq with getLocalConfValue
This commit is contained in:
parent
30ae3e1926
commit
d97fe62301
1 changed files with 2 additions and 2 deletions
|
@ -38,8 +38,8 @@ function startpod() {
|
|||
cd "$(getValueByKey 'PODMAN_DIRECTORY')/${1}"
|
||||
|
||||
# check if network is needed
|
||||
if [[ -n $(jq -r .network.name "$(getValueByKey 'PODMAN_DIRECTORY')/${1}/config.json") ]]; then
|
||||
local network="$(jq -r .network.name $(getValueByKey 'PODMAN_DIRECTORY')/${1}/config.json)"
|
||||
if [[ -n $(getLocalConfValue $(getValueByKey 'PODMAN_DIRECTORY')/${1} network.name) ]]; then
|
||||
local network="$(getLocalConfValue $(getValueByKey 'PODMAN_DIRECTORY')/${1} network.name)"
|
||||
if [[ -z $(podman network ls | grep "$network") ]]; then
|
||||
podman network create "$network"
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue