mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-08-18 17:53:29 +00:00
update deploy script to ensure target linux
This commit is contained in:
+4
-4
@@ -18,20 +18,20 @@ fi
|
|||||||
if [[ "$ENV" == "dev" ]]; then
|
if [[ "$ENV" == "dev" ]]; then
|
||||||
INSTANCE_NAME="openfrontio-dev-instance"
|
INSTANCE_NAME="openfrontio-dev-instance"
|
||||||
TAG="dev"
|
TAG="dev"
|
||||||
GAME_ENV="preprod" # Set game environment to preprod for dev
|
GAME_ENV="preprod"
|
||||||
echo "[DEV] Deploying to openfront.dev"
|
echo "[DEV] Deploying to openfront.dev"
|
||||||
else
|
else
|
||||||
INSTANCE_NAME="openfrontio-instance"
|
INSTANCE_NAME="openfrontio-instance"
|
||||||
TAG="latest"
|
TAG="latest"
|
||||||
GAME_ENV="prod" # Set game environment to prod for prod
|
GAME_ENV="prod"
|
||||||
echo "[PROD] Deploying to openfront.io"
|
echo "[PROD] Deploying to openfront.io"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Ensure you're authenticated with Google Cloud
|
# Ensure you're authenticated with Google Cloud
|
||||||
gcloud auth configure-docker us-central1-docker.pkg.dev
|
gcloud auth configure-docker us-central1-docker.pkg.dev
|
||||||
|
|
||||||
# Build the new Docker image with GAME_ENV build argument
|
# Build the new Docker image with platform specification and GAME_ENV build argument
|
||||||
docker build --build-arg GAME_ENV=$GAME_ENV -t openfrontio .
|
docker build --platform linux/amd64 --build-arg GAME_ENV=$GAME_ENV -t openfrontio .
|
||||||
|
|
||||||
# Tag the new image
|
# Tag the new image
|
||||||
docker tag openfrontio us-central1-docker.pkg.dev/openfrontio/openfrontio/game-server:$TAG
|
docker tag openfrontio us-central1-docker.pkg.dev/openfrontio/openfrontio/game-server:$TAG
|
||||||
|
|||||||
Reference in New Issue
Block a user