Files
abra/tests/integration/helpers/docker.bash
decentral1se 4193d63d23
All checks were successful
continuous-integration/drone/pr Build is passing
continuous-integration/drone/push Build is passing
test: advertise locally to avoid multiple ip error
2025-08-17 14:04:00 +02:00

14 lines
339 B
Bash

#!/usr/bin/env bash
_ensure_swarm() {
if [ "$(docker info | grep Swarm | sed 's/Swarm: //g' | tr -d ' ')" == "inactive" ]; then
run docker swarm init --advertise-addr 127.0.0.1:2377
assert_success
fi
if ! $(docker network ls | grep -q 'proxy'); then
run docker network create -d overlay proxy
assert_success
fi
}