Skip to content

Commit

Permalink
test: make run-builder.sh work with podman 4
Browse files Browse the repository at this point in the history
RHEL is now shipping podman 4 that encodes the networks differently, let's
implement a small dirty hack to fix it on RHEL before
#100 can land and fix it properly.
  • Loading branch information
ondrejbudai authored and gicmo committed Jun 29, 2022
1 parent 12773db commit 3930f27
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion test/run-builder.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,12 @@ else
fi

builder_start() {
GATEWAY_IP=$(${CONTAINER_RUNTIME} network inspect org.osbuild.koji | jq -r ".[0].plugins[0].ipam.ranges[0][0].gateway")
source /etc/os-release
if [[ $ID == rhel ]]; then
GATEWAY_IP=$(${CONTAINER_RUNTIME} network inspect org.osbuild.koji | jq -r ".[0].subnets[0].gateway")
else
GATEWAY_IP=$(${CONTAINER_RUNTIME} network inspect org.osbuild.koji | jq -r ".[0].plugins[0].ipam.ranges[0][0].gateway")
fi
echo "Gateway IP is $GATEWAY_IP"

# maybe copy the 'builder' plugin to the share dir
Expand Down

0 comments on commit 3930f27

Please sign in to comment.