From ee11572646f60867c5e41544f0f9b55c9785159a Mon Sep 17 00:00:00 2001 From: Luke Childs Date: Thu, 7 Nov 2019 23:20:35 +0700 Subject: [PATCH] Remove hardcoded volume id --- checkvolumesize | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/checkvolumesize b/checkvolumesize index 2b8fb74..11d2500 100755 --- a/checkvolumesize +++ b/checkvolumesize @@ -184,7 +184,7 @@ main () { # Increase volume size new_volume_size=$(expr $volume_size + $BUFFER) log "Increasing volume size to ${new_volume_size}GB..." - action_json=$(digital_ocean_api "volumes/2cbebc6a-ff42-11e9-a238-0a58ac14a19d/actions" '{"type":"resize","size_gigabytes":'$new_volume_size'}') + action_json=$(digital_ocean_api "volumes/${volume_id}/actions" '{"type":"resize","size_gigabytes":'$new_volume_size'}') action_id=$(echo $action_json | jq -r '.action.id') log "Created action \"${action_id}\""