diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-05 21:04:41 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-05 21:04:41 +0000 |
commit | a51106ed6932423c25c7d464ef5c2d609bd62924 (patch) | |
tree | b40cd0bcb45e9d56ee030c434e79351cfe57e1b3 /heartbeat/openstack-info.in | |
parent | Adding upstream version 1:4.13.0. (diff) | |
download | resource-agents-upstream/1%4.14.0.tar.xz resource-agents-upstream/1%4.14.0.zip |
Adding upstream version 1:4.14.0.upstream/1%4.14.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rwxr-xr-x | heartbeat/openstack-info.in | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/heartbeat/openstack-info.in b/heartbeat/openstack-info.in index 6502f1d..876e833 100755 --- a/heartbeat/openstack-info.in +++ b/heartbeat/openstack-info.in @@ -164,10 +164,12 @@ OSInfoStats() { --format json \ --column fixed_ips \ ${port_id}") - subnet_id=$(echo "$subnet_result" | + subnet_ids=$(echo "$subnet_result" | grep -P '\"subnet_id\": \".*\",$' | grep -P -o '[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}') - value="${value}${subnet_id}:${port_id}," + for subnet_id in $subnet_ids; do + value="${value}${subnet_id}:${port_id}," + done done value=${value%,} |