Pass in api url
This commit is contained in:
parent
447a38f519
commit
12e0d87388
2 changed files with 10 additions and 1 deletions
|
@ -7,6 +7,10 @@ REGISTRY="docker.botris.dev"
|
|||
USERNAME="johnbotris"
|
||||
IMAGE_NAME="femto-webapp"
|
||||
|
||||
# Add this before the docker build line
|
||||
export VITE_API_URL="https://femto-api.botris.social"
|
||||
|
||||
|
||||
# Step 0: Ensure clean working directory
|
||||
if [[ -n $(git status --porcelain) ]]; then
|
||||
echo "❌ Uncommitted changes detected. Please commit or stash them before running this script."
|
||||
|
@ -25,7 +29,8 @@ echo "📦 New version: $NEW_VERSION"
|
|||
|
||||
# Step 3: Attempt Docker build
|
||||
echo "🔧 Building Docker image..."
|
||||
if ! docker build -t $IMAGE_NAME .; then
|
||||
|
||||
if ! docker build --build-arg VITE_API_URL="$VITE_API_URL" -t $IMAGE_NAME .; then
|
||||
echo "❌ Docker build failed. Reverting version bump..."
|
||||
git checkout -- package.json yarn.lock
|
||||
exit 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue