From 3047e1a157fad968cc5f6e620d5cbe5c0867fffd Mon Sep 17 00:00:00 2001 From: Joao Patricio Date: Thu, 8 Feb 2024 15:24:21 +0000 Subject: [PATCH] Fix open in browser with APP_PORT (#663) * Fix open in browser with APP_PORT * Update sail --------- Co-authored-by: Taylor Otwell --- bin/sail | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/bin/sail b/bin/sail index b7995f98..a126852d 100755 --- a/bin/sail +++ b/bin/sail @@ -560,7 +560,14 @@ elif [ "$1" == "open" ]; then shift 1 if [ "$EXEC" == "yes" ]; then - open "$APP_URL" + + if [[ -n "$APP_PORT" && "$APP_PORT" != "80" ]]; then + FULL_URL="${APP_URL}:${APP_PORT}" + else + FULL_URL="$APP_URL" + fi + + open "$FULL_URL" exit else