Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add .env file to be able to run the server manually in Office Argentina server (macOS) #966

Merged
merged 4 commits into from
Nov 5, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions devops/deploy-macos.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,33 @@ if [ ${RELEASE} == "central_backend" ]; then
mix ecto.migrate
fi

cat <<EOF >$HOME/.env${_SERVICE_SUFFIX}
PHX_HOST=${PHX_HOST}
DATABASE_URL=${DATABASE_URL}
PHX_SERVER=${PHX_SERVER}
SECRET_KEY_BASE=${SECRET_KEY_BASE}
JWT_PRIVATE_KEY_BASE_64=${JWT_PRIVATE_KEY_BASE_64}
PORT=${PORT}
RELEASE_NODE=${RELEASE_NODE}
_SERVICE_SUFFIX=${_SERVICE_SUFFIX}
GATEWAY_URL=${GATEWAY_URL}
METRICS_ENDPOINT_PORT=${METRICS_ENDPOINT_PORT}
OVERRIDE_JWT=${OVERRIDE_JWT}
GOOGLE_CLIENT_ID=${GOOGLE_CLIENT_ID}
BOT_MANAGER_PORT=${BOT_MANAGER_PORT}
BOT_MANAGER_HOST=${BOT_MANAGER_HOST}
CONFIGURATOR_HOST=${CONFIGURATOR_HOST}
CONFIGURATOR_GOOGLE_CLIENT_ID=${CONFIGURATOR_GOOGLE_CLIENT_ID}
CONFIGURATOR_GOOGLE_CLIENT_SECRET=${CONFIGURATOR_GOOGLE_CLIENT_SECRET}
RELEASE=${RELEASE}
TARGET_SERVER=${TARGET_SERVER}
LOADTEST_EUROPE_HOST=${LOADTEST_EUROPE_HOST}
LOADTEST_BRAZIL_HOST=${LOADTEST_BRAZIL_HOST}
LOADTEST_CHILE_HOST=${LOADTEST_CHILE_HOST}
NEWRELIC_APP_NAME=${NEWRELIC_APP_NAME}
NEWRELIC_KEY=${NEWRELIC_KEY}
EOF

export PHX_HOST=$PHX_HOST
export DATABASE_URL=$DATABASE_URL
export PHX_SERVER=$PHX_SERVER
Expand Down Expand Up @@ -54,4 +81,6 @@ export NEWRELIC_KEY=$NEWRELIC_KEY
rm -rf ${HOME}/arena/mirra_backend
mv /tmp/mirra_backend ${HOME}/arena/

export $(cat .env | xargs)

/Users/lambdaclass/arena/mirra_backend/_build/prod/rel/arena/bin/arena daemon
Loading