diff --git a/deploy/selfhost/README.md b/deploy/selfhost/README.md index c44771882c7..d93d85ca14d 100644 --- a/deploy/selfhost/README.md +++ b/deploy/selfhost/README.md @@ -10,7 +10,7 @@ Let's get started!
Option 1 - Using Cloud Server -

Best way to start is to create EC2 maching on AWS. It must of minimum t3.medium/t3a/medium

+

Best way to start is to create EC2 machine on AWS. It must have minimum of 2vCPU and 4GB RAM.

Run the below command to install docker engine.

`curl -fsSL https://get.docker.com | sh -` @@ -67,23 +67,6 @@ curl -fsSL -o setup.sh https://raw.githubusercontent.com/makeplane/plane/master/ chmod +x setup.sh ``` -
- Downloading Preview Release - -``` -mkdir plane-selfhost - -cd plane-selfhost - -export RELEASE=preview - -curl -fsSL https://raw.githubusercontent.com/makeplane/plane/$BRANCH/deploy/selfhost/install.sh | sed 's@BRANCH=master@BRANCH='"$RELEASE"'@' > setup.sh - -chmod +x setup.sh -``` - -
- --- ### Proceed with setup @@ -114,7 +97,7 @@ This will create a create a folder `plane-app` or `plane-app-preview` (in case o - `docker-compose.yaml` - `plane.env` -Again the `options [1-7]` will be popped up and this time hit `7` to exit. +Again the `options [1-8]` will be popped up and this time hit `8` to exit. --- @@ -236,7 +219,7 @@ Select a Action you want to perform: Action [2]: 5 ``` -By choosing this, it will stop the services and then will download the latest `docker-compose.yaml` and `variables-upgrade.env`. Here system will not replace `.env` with the new one. +By choosing this, it will stop the services and then will download the latest `docker-compose.yaml` and `plane.env`. You must expect the below message @@ -244,7 +227,7 @@ You must expect the below message Once done, choose `8` to exit from prompt. -> It is very important for you to compare the 2 files `variables-upgrade.env` and `.env`. Copy the newly added variable from downloaded file to `.env` and set the expected values. +> It is very important for you to validate the `plane.env` for the new changes. Once done with making changes in `plane.env` file, jump on to `Start Server` diff --git a/deploy/selfhost/build.yml b/deploy/selfhost/build.yml index e81701f5d39..b65d297e9fd 100644 --- a/deploy/selfhost/build.yml +++ b/deploy/selfhost/build.yml @@ -1,5 +1,3 @@ -version: "3.8" - services: web: image: ${DOCKERHUB_USER:-local}/plane-frontend:${APP_RELEASE:-latest} diff --git a/deploy/selfhost/docker-compose.yml b/deploy/selfhost/docker-compose.yml index 5a7b1acfc66..638452fd761 100644 --- a/deploy/selfhost/docker-compose.yml +++ b/deploy/selfhost/docker-compose.yml @@ -44,7 +44,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-frontend:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: unless-stopped command: node web/server.js web deploy: @@ -57,7 +57,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-space:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: unless-stopped command: node space/server.js space deploy: @@ -71,7 +71,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-admin:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: unless-stopped command: node admin/server.js admin deploy: @@ -84,7 +84,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-backend:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: unless-stopped command: ./bin/docker-entrypoint-api.sh deploy: @@ -99,7 +99,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-backend:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: unless-stopped command: ./bin/docker-entrypoint-worker.sh volumes: @@ -113,7 +113,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-backend:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: unless-stopped command: ./bin/docker-entrypoint-beat.sh volumes: @@ -127,7 +127,7 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-backend:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present restart: "no" command: ./bin/docker-entrypoint-migrator.sh volumes: @@ -167,7 +167,8 @@ services: <<: *app-env image: ${DOCKERHUB_USER:-makeplane}/plane-proxy:${APP_RELEASE:-stable} platform: ${DOCKER_PLATFORM:-} - pull_policy: ${PULL_POLICY:-always} + pull_policy: if_not_present + restart: unless-stopped ports: - ${NGINX_PORT}:80 depends_on: diff --git a/deploy/selfhost/install.sh b/deploy/selfhost/install.sh index fb248509aa3..8fd2e3e2fa1 100755 --- a/deploy/selfhost/install.sh +++ b/deploy/selfhost/install.sh @@ -1,18 +1,18 @@ #!/bin/bash -BRANCH=master +BRANCH=${BRANCH:-master} SCRIPT_DIR=$PWD SERVICE_FOLDER=plane-app PLANE_INSTALL_DIR=$PWD/$SERVICE_FOLDER -export APP_RELEASE=$BRANCH +export APP_RELEASE="stable" export DOCKERHUB_USER=makeplane -export PULL_POLICY=always -USE_GLOBAL_IMAGES=1 +export PULL_POLICY=${PULL_POLICY:-if_not_present} -RED='\033[0;31m' -YELLOW='\033[1;33m' -GREEN='\033[0;32m' -NC='\033[0m' # No Color +CPU_ARCH=$(uname -m) + +mkdir -p $PLANE_INSTALL_DIR/archive +DOCKER_FILE_PATH=$PLANE_INSTALL_DIR/docker-compose.yaml +DOCKER_ENV_PATH=$PLANE_INSTALL_DIR/plane.env function print_header() { clear @@ -31,65 +31,191 @@ Project management tool from the future EOF } -function buildLocalImage() { - if [ "$1" == "--force-build" ]; then - DO_BUILD="1" - elif [ "$1" == "--skip-build" ]; then - DO_BUILD="2" - else - printf "\n" >&2 - printf "${YELLOW}You are on ${CPU_ARCH} cpu architecture. ${NC}\n" >&2 - printf "${YELLOW}Since the prebuilt ${CPU_ARCH} compatible docker images are not available for, we will be running the docker build on this system. ${NC} \n" >&2 - printf "${YELLOW}This might take ${YELLOW}5-30 min based on your system's hardware configuration. \n ${NC} \n" >&2 - printf "\n" >&2 - printf "${GREEN}Select an option to proceed: ${NC}\n" >&2 - printf " 1) Build Fresh Images \n" >&2 - printf " 2) Skip Building Images \n" >&2 - printf " 3) Exit \n" >&2 - printf "\n" >&2 - read -p "Select Option [1]: " DO_BUILD - until [[ -z "$DO_BUILD" || "$DO_BUILD" =~ ^[1-3]$ ]]; do - echo "$DO_BUILD: invalid selection." >&2 - read -p "Select Option [1]: " DO_BUILD - done +function spinner() { + local pid=$1 + local delay=.5 + local spinstr='|/-\' + + if ! ps -p "$pid" > /dev/null; then + echo "Invalid PID: $pid" + return 1 + fi + while ps -p "$pid" > /dev/null; do + local temp=${spinstr#?} + printf " [%c] " "$spinstr" >&2 + local spinstr=$temp${spinstr%"$temp"} + sleep $delay + printf "\b\b\b\b\b\b" >&2 + done + printf " \b\b\b\b" >&2 +} + +function initialize(){ + printf "Please wait while we check the availability of Docker images for the selected release ($APP_RELEASE) with ${CPU_ARCH^^} support." >&2 + + if [ "$CUSTOM_BUILD" == "true" ]; then echo "" >&2 + echo "" >&2 + echo "${CPU_ARCH^^} images are not available for selected release ($APP_RELEASE)." >&2 + echo "build" + return 1 fi - if [ "$DO_BUILD" == "1" ] || [ "$DO_BUILD" == "" ]; - then - REPO=https://github.com/makeplane/plane.git - CURR_DIR=$PWD - PLANE_TEMP_CODE_DIR=$(mktemp -d) - git clone $REPO $PLANE_TEMP_CODE_DIR --branch $BRANCH --single-branch + local IMAGE_NAME=makeplane/plane-proxy + local IMAGE_TAG=${APP_RELEASE} + docker manifest inspect "${IMAGE_NAME}:${IMAGE_TAG}" | grep -q "\"architecture\": \"${CPU_ARCH}\"" & + local pid=$! + spinner "$pid" + + echo "" >&2 - cp $PLANE_TEMP_CODE_DIR/deploy/selfhost/build.yml $PLANE_TEMP_CODE_DIR/build.yml + wait "$pid" - cd $PLANE_TEMP_CODE_DIR - if [ "$BRANCH" == "master" ]; - then - export APP_RELEASE=stable + if [ $? -eq 0 ]; then + echo "Plane supports ${CPU_ARCH}" >&2 + echo "available" + return 0 + else + echo "" >&2 + echo "" >&2 + echo "${CPU_ARCH^^} images are not available for selected release ($APP_RELEASE)." >&2 + echo "" >&2 + echo "build" + return 1 + fi +} +function getEnvValue() { + local key=$1 + local file=$2 + + if [ -z "$key" ] || [ -z "$file" ]; then + echo "Invalid arguments supplied" + exit 1 + fi + + if [ -f "$file" ]; then + grep -q "^$key=" "$file" + if [ $? -eq 0 ]; then + local value + value=$(grep "^$key=" "$file" | cut -d'=' -f2) + echo "$value" + else + echo "" fi + fi +} +function updateEnvFile() { + local key=$1 + local value=$2 + local file=$3 - /bin/bash -c "$COMPOSE_CMD -f build.yml build --no-cache" >&2 - # cd $CURR_DIR - # rm -rf $PLANE_TEMP_CODE_DIR - echo "build_completed" - elif [ "$DO_BUILD" == "2" ]; - then - printf "${YELLOW}Build action skipped by you in lieu of using existing images. ${NC} \n" >&2 - echo "build_skipped" - elif [ "$DO_BUILD" == "3" ]; - then - echo "build_exited" + if [ -z "$key" ] || [ -z "$value" ] || [ -z "$file" ]; then + echo "Invalid arguments supplied" + exit 1 + fi + + if [ -f "$file" ]; then + # check if key exists in the file + grep -q "^$key=" "$file" + if [ $? -ne 0 ]; then + echo "$key=$value" >> "$file" + return + else + # if key exists, update the value + sed -i "s/^$key=.*/$key=$value/g" "$file" + fi else - printf "INVALID OPTION SUPPLIED" >&2 + echo "File not found: $file" + exit 1 + fi +} + +function updateCustomVariables(){ + echo "Updating custom variables..." >&2 + updateEnvFile "DOCKERHUB_USER" "$DOCKERHUB_USER" "$DOCKER_ENV_PATH" + updateEnvFile "APP_RELEASE" "$APP_RELEASE" "$DOCKER_ENV_PATH" + updateEnvFile "PULL_POLICY" "$PULL_POLICY" "$DOCKER_ENV_PATH" + updateEnvFile "CUSTOM_BUILD" "$CUSTOM_BUILD" "$DOCKER_ENV_PATH" + echo "Custom variables updated successfully" >&2 +} + +function syncEnvFile(){ + echo "Syncing environment variables..." >&2 + if [ -f "$PLANE_INSTALL_DIR/plane.env.bak" ]; then + updateCustomVariables + + # READ keys of plane.env and update the values from plane.env.bak + while IFS= read -r line + do + # ignore is the line is empty or starts with # + if [ -z "$line" ] || [[ $line == \#* ]]; then + continue + fi + key=$(echo "$line" | cut -d'=' -f1) + value=$(getEnvValue "$key" "$PLANE_INSTALL_DIR/plane.env.bak") + if [ -n "$value" ]; then + updateEnvFile "$key" "$value" "$DOCKER_ENV_PATH" + fi + done < "$DOCKER_ENV_PATH" fi + echo "Environment variables synced successfully" >&2 } + +function buildYourOwnImage(){ + echo "Building images locally..." + + export DOCKERHUB_USER="myplane" + export APP_RELEASE="local" + export PULL_POLICY="never" + CUSTOM_BUILD="true" + + # checkout the code to ~/tmp/plane folder and build the images + local PLANE_TEMP_CODE_DIR=~/tmp/plane + rm -rf $PLANE_TEMP_CODE_DIR + mkdir -p $PLANE_TEMP_CODE_DIR + REPO=https://github.com/makeplane/plane.git + git clone "$REPO" "$PLANE_TEMP_CODE_DIR" --branch "$BRANCH" --single-branch --depth 1 + + cp "$PLANE_TEMP_CODE_DIR/deploy/selfhost/build.yml" "$PLANE_TEMP_CODE_DIR/build.yml" + + cd "$PLANE_TEMP_CODE_DIR" || exit + + /bin/bash -c "$COMPOSE_CMD -f build.yml build --no-cache" >&2 + if [ $? -ne 0 ]; then + echo "Build failed. Exiting..." + exit 1 + fi + echo "Build completed successfully" + echo "" + echo "You can now start the services by running the command: ./setup.sh start" + echo "" +} + function install() { - echo "Installing Plane.........." - download + echo "Begin Installing Plane" + echo "" + + local build_image=$(initialize) + + if [ "$build_image" == "build" ]; then + # ask for confirmation to continue building the images + echo "Do you want to continue with building the Docker images locally?" + read -p "Continue? [y/N]: " confirm + if [[ ! "$confirm" =~ ^[Yy]$ ]]; then + echo "Exiting..." + exit 0 + fi + fi + + if [ "$build_image" == "build" ]; then + download "true" + else + download "false" + fi } + function download() { + local LOCAL_BUILD=$1 cd $SCRIPT_DIR TS=$(date +%s) if [ -f "$PLANE_INSTALL_DIR/docker-compose.yaml" ] @@ -102,44 +228,48 @@ function download() { if [ -f "$DOCKER_ENV_PATH" ]; then - cp $DOCKER_ENV_PATH $PLANE_INSTALL_DIR/archive/$TS.env - else - mv $PLANE_INSTALL_DIR/variables-upgrade.env $DOCKER_ENV_PATH + cp "$DOCKER_ENV_PATH" "$PLANE_INSTALL_DIR/archive/$TS.env" + cp "$DOCKER_ENV_PATH" "$PLANE_INSTALL_DIR/plane.env.bak" fi - if [ "$BRANCH" != "master" ]; - then - cp $PLANE_INSTALL_DIR/docker-compose.yaml $PLANE_INSTALL_DIR/temp.yaml - sed -e 's@${APP_RELEASE:-stable}@'"$BRANCH"'@g' \ - $PLANE_INSTALL_DIR/temp.yaml > $PLANE_INSTALL_DIR/docker-compose.yaml + mv $PLANE_INSTALL_DIR/variables-upgrade.env $DOCKER_ENV_PATH - rm $PLANE_INSTALL_DIR/temp.yaml - fi + syncEnvFile - if [ $USE_GLOBAL_IMAGES == 0 ]; then - local res=$(buildLocalImage) - # echo $res + if [ "$LOCAL_BUILD" == "true" ]; then + export DOCKERHUB_USER="myplane" + export APP_RELEASE="local" + export PULL_POLICY="never" + CUSTOM_BUILD="true" - if [ "$res" == "build_exited" ]; - then - echo - echo "Install action cancelled by you. Exiting now." - echo - exit 0 + buildYourOwnImage + + if [ $? -ne 0 ]; then + echo "" + echo "Build failed. Exiting..." + exit 1 fi + updateCustomVariables else - /bin/bash -c "$COMPOSE_CMD -f $DOCKER_FILE_PATH --env-file=$DOCKER_ENV_PATH pull" + CUSTOM_BUILD="false" + updateCustomVariables + /bin/bash -c "$COMPOSE_CMD -f $DOCKER_FILE_PATH --env-file=$DOCKER_ENV_PATH pull --policy always" + + if [ $? -ne 0 ]; then + echo "" + echo "Failed to pull the images. Exiting..." + exit 1 + fi fi echo "" - echo "Most recent Stable version is now available for you to use" + echo "Most recent version of Plane is now available for you to use" echo "" - echo "In case of Upgrade, your new setting file is availabe as 'variables-upgrade.env'. Please compare and set the required values in 'plane.env 'file." + echo "In case of 'Upgrade', please check the 'plane.env 'file for any new variables and update them accordingly" echo "" - } function startServices() { - /bin/bash -c "$COMPOSE_CMD -f $DOCKER_FILE_PATH --env-file=$DOCKER_ENV_PATH up -d --quiet-pull" + /bin/bash -c "$COMPOSE_CMD -f $DOCKER_FILE_PATH --env-file=$DOCKER_ENV_PATH up -d --pull if_not_present --quiet-pull" local migrator_container_id=$(docker container ls -aq -f "name=$SERVICE_FOLDER-migrator") if [ -n "$migrator_container_id" ]; then @@ -201,7 +331,7 @@ function upgrade() { echo echo "***** DOWNLOADING STABLE VERSION ****" - download + install echo "***** PLEASE VALIDATE AND START SERVICES ****" } @@ -282,7 +412,6 @@ function viewLogs(){ echo "INVALID SERVICE NAME SUPPLIED" fi } - function backupSingleVolume() { backupFolder=$1 selectedVolume=$2 @@ -299,7 +428,6 @@ function backupSingleVolume() { -v "$backupFolder":/backup \ busybox sh -c 'tar -czf "/backup/${TAR_NAME}.tar.gz" /${TAR_NAME}' } - function backupData() { local datetime=$(date +"%Y%m%d-%H%M") local BACKUP_FOLDER=$PLANE_INSTALL_DIR/backup/$datetime @@ -329,7 +457,7 @@ function askForAction() { then echo echo "Select a Action you want to perform:" - echo " 1) Install (${CPU_ARCH})" + echo " 1) Install" echo " 2) Start" echo " 3) Stop" echo " 4) Restart" @@ -351,31 +479,31 @@ function askForAction() { echo fi - if [ "$ACTION" == "1" ] || [ "$DEFAULT_ACTION" == "install" ] + if [ "$ACTION" == "1" ] || [ "$DEFAULT_ACTION" == "install" ]; then install - askForAction - elif [ "$ACTION" == "2" ] || [ "$DEFAULT_ACTION" == "start" ] + # askForAction + elif [ "$ACTION" == "2" ] || [ "$DEFAULT_ACTION" == "start" ]; then startServices # askForAction - elif [ "$ACTION" == "3" ] || [ "$DEFAULT_ACTION" == "stop" ] + elif [ "$ACTION" == "3" ] || [ "$DEFAULT_ACTION" == "stop" ]; then stopServices # askForAction - elif [ "$ACTION" == "4" ] || [ "$DEFAULT_ACTION" == "restart" ] + elif [ "$ACTION" == "4" ] || [ "$DEFAULT_ACTION" == "restart" ]; then restartServices # askForAction - elif [ "$ACTION" == "5" ] || [ "$DEFAULT_ACTION" == "upgrade" ] + elif [ "$ACTION" == "5" ] || [ "$DEFAULT_ACTION" == "upgrade" ]; then upgrade - askForAction - elif [ "$ACTION" == "6" ] || [ "$DEFAULT_ACTION" == "logs" ] + # askForAction + elif [ "$ACTION" == "6" ] || [ "$DEFAULT_ACTION" == "logs" ]; then - viewLogs $@ + viewLogs "$@" askForAction - elif [ "$ACTION" == "7" ] || [ "$DEFAULT_ACTION" == "backup" ] + elif [ "$ACTION" == "7" ] || [ "$DEFAULT_ACTION" == "backup" ]; then backupData elif [ "$ACTION" == "8" ] @@ -394,48 +522,38 @@ else COMPOSE_CMD="docker compose" fi -# CPU ARCHITECHTURE BASED SETTINGS -CPU_ARCH=$(uname -m) -if [[ $FORCE_CPU == "amd64" || $CPU_ARCH == "amd64" || $CPU_ARCH == "x86_64" || ( $BRANCH == "master" && ( $CPU_ARCH == "arm64" || $CPU_ARCH == "aarch64" ) ) ]]; -then - USE_GLOBAL_IMAGES=1 - DOCKERHUB_USER=makeplane - PULL_POLICY=always -else - USE_GLOBAL_IMAGES=0 - DOCKERHUB_USER=myplane - PULL_POLICY=never +if [ "$CPU_ARCH" == "x86_64" ] || [ "$CPU_ARCH" == "amd64" ]; then + CPU_ARCH="amd64" +elif [ "$CPU_ARCH" == "aarch64" ] || [ "$CPU_ARCH" == "arm64" ]; then + CPU_ARCH="arm64" fi -if [ "$BRANCH" == "master" ]; -then - export APP_RELEASE=stable -fi +if [ -f "$DOCKER_ENV_PATH" ]; then + DOCKERHUB_USER=$(getEnvValue "DOCKERHUB_USER" "$DOCKER_ENV_PATH") + APP_RELEASE=$(getEnvValue "APP_RELEASE" "$DOCKER_ENV_PATH") + PULL_POLICY=$(getEnvValue "PULL_POLICY" "$DOCKER_ENV_PATH") + CUSTOM_BUILD=$(getEnvValue "CUSTOM_BUILD" "$DOCKER_ENV_PATH") -# REMOVE SPECIAL CHARACTERS FROM BRANCH NAME -if [ "$BRANCH" != "master" ]; -then - SERVICE_FOLDER=plane-app-$(echo $BRANCH | sed -r 's@(\/|" "|\.)@-@g') - PLANE_INSTALL_DIR=$PWD/$SERVICE_FOLDER -fi -mkdir -p $PLANE_INSTALL_DIR/archive + if [ -z "$DOCKERHUB_USER" ]; then + DOCKERHUB_USER=makeplane + updateEnvFile "DOCKERHUB_USER" "$DOCKERHUB_USER" "$DOCKER_ENV_PATH" + fi -DOCKER_FILE_PATH=$PLANE_INSTALL_DIR/docker-compose.yaml -DOCKER_ENV_PATH=$PLANE_INSTALL_DIR/plane.env + if [ -z "$APP_RELEASE" ]; then + APP_RELEASE=stable + updateEnvFile "APP_RELEASE" "$APP_RELEASE" "$DOCKER_ENV_PATH" + fi -# BACKWARD COMPATIBILITY -OLD_DOCKER_ENV_PATH=$PLANE_INSTALL_DIR/.env -if [ -f "$OLD_DOCKER_ENV_PATH" ]; -then - mv "$OLD_DOCKER_ENV_PATH" "$DOCKER_ENV_PATH" - OS_NAME=$(uname) - if [ "$OS_NAME" == "Darwin" ]; - then - sed -i '' -e 's@APP_RELEASE=latest@APP_RELEASE=stable@' "$DOCKER_ENV_PATH" - else - sed -i -e 's@APP_RELEASE=latest@APP_RELEASE=stable@' "$DOCKER_ENV_PATH" + if [ -z "$PULL_POLICY" ]; then + PULL_POLICY=if_not_present + updateEnvFile "PULL_POLICY" "$PULL_POLICY" "$DOCKER_ENV_PATH" + fi + + if [ -z "$CUSTOM_BUILD" ]; then + CUSTOM_BUILD=false + updateEnvFile "CUSTOM_BUILD" "$CUSTOM_BUILD" "$DOCKER_ENV_PATH" fi fi print_header -askForAction $@ +askForAction "$@" diff --git a/deploy/selfhost/variables.env b/deploy/selfhost/variables.env index 08f686c80a4..4120ee502aa 100644 --- a/deploy/selfhost/variables.env +++ b/deploy/selfhost/variables.env @@ -1,3 +1,4 @@ +APP_DOMAIN=localhost APP_RELEASE=stable WEB_REPLICAS=1 @@ -6,11 +7,11 @@ ADMIN_REPLICAS=1 API_REPLICAS=1 NGINX_PORT=80 -WEB_URL=http://localhost +WEB_URL=http://${APP_DOMAIN} DEBUG=0 SENTRY_DSN= SENTRY_ENVIRONMENT=production -CORS_ALLOWED_ORIGINS=http://localhost +CORS_ALLOWED_ORIGINS=http://${APP_DOMAIN} #DB SETTINGS PGHOST=plane-db @@ -46,4 +47,5 @@ FILE_SIZE_LIMIT=5242880 GUNICORN_WORKERS=1 # UNCOMMENT `DOCKER_PLATFORM` IF YOU ARE ON `ARM64` AND DOCKER IMAGE IS NOT AVAILABLE FOR RESPECTIVE `APP_RELEASE` -# DOCKER_PLATFORM=linux/amd64 \ No newline at end of file +# DOCKER_PLATFORM=linux/amd64 +