Skip to content

Commit

Permalink
Check OrbStack IP before Docker Desktop IP
Browse files Browse the repository at this point in the history
  • Loading branch information
dpfaffenbauer authored Mar 6, 2024
1 parent 336e178 commit 6f2bcf8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions files/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ EOF
# if XDEBUG_HOST is manually set
HOST="$XDEBUG_HOST"

# else if check if is Docker for Mac
# OrbStack
if [ -z "$HOST" ]; then
HOST=`getent hosts docker.for.mac.localhost | awk '{ print $1 }'`
HOST=`getent ahostsv4 host.internal | awk 'NR==1{ print $1 }'`
fi

# OrbStack
# else if check if is Docker for Mac
if [ -z "$HOST" ]; then
HOST=`getent ahostsv4 host.internal | awk 'NR==1{ print $1 }'`
HOST=`getent hosts docker.for.mac.localhost | awk '{ print $1 }'`
fi

# else get host ip
Expand Down

0 comments on commit 6f2bcf8

Please sign in to comment.