Update action.yml

This commit is contained in:
Igor
2023-09-17 14:29:49 +02:00
committed by GitHub
parent 1d0b614397
commit b4064886bb

View File

@@ -71,10 +71,10 @@ runs:
SERVERS=(${{ inputs.failoverserver }})
#fi
for server in "${SERVERS[@]}"; do
for server_id in "${SERVERS[@]}"; do
unset REGION LATITUDE LONGITUDE
COMMAND=$(curl -sH "Authorization: Token ${{ inputs.netbox }}" -H "Accept: application/json; indent=4" \
"https://stuff.armbian.com/netbox/api/virtualization/virtual-machines/?limit=500&name__empty=false&name=$server" | jq)
"https://stuff.armbian.com/netbox/api/virtualization/virtual-machines/?limit=500&name__empty=false&id=$server_id" | jq)
# where paths has been altered by mirror
DL_PATH_DEBS=$(echo $COMMAND | jq '.results[] | .custom_fields["download_path_debs"]' | sed "s/\"//g")
DL_PATH_IMAGES=$(echo $COMMAND | jq '.results[] | .custom_fields["download_path_images"]' | sed "s/\"//g")