Skip to content

Commit

Permalink
Speed up deploys by using a remote builder unless local is specified …
Browse files Browse the repository at this point in the history
…explicitly
  • Loading branch information
Joshua Sierles committed Feb 2, 2022
1 parent 06ea104 commit 372a8fc
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,19 @@ if [ -n "$FLY_PROJECT_PATH" ]; then
# Allow user to change directories in which to run Fly commands
cd "$FLY_PROJECT_PATH" || exit
fi
sh -c "flyctl $*"


# Default to deploying with a remote builder unless local is specified explicitly
STRATEGY="--remote-only"

for i in "$*" ; do
if [[ $i == "--local-only" ]] ; then
STRATEGY="--local-only"
break
fi
done

sh -c "flyctl $* $STRATEGY"

ACTUAL_EXIT="$?"

Expand Down

0 comments on commit 372a8fc

Please sign in to comment.