hotpocket/services/base/ops/bin/entrypoint.sh
Tomek Wójcik b4338e2769
Some checks failed
CI / Checks (push) Failing after 13m2s
Release v1.0.0
2025-08-20 21:00:50 +02:00

29 lines
598 B
Bash
Executable File

#!/bin/bash
set -e
export PYTHONPATH="/srv/app:$PYTHONPATH"
SETUP_BACKEND=${SETUP_BACKEND:-"false"}
SETUP_FRONTEND=${SETUP_FRONTEND:-"false"}
/srv/bin/wait-for-cloud.sh
if [ "${SETUP_BACKEND}" = "true" ];then
if [ "${RUN_POETRY_INSTALL}" = "true" ];then
poetry install --no-ansi --no-cache
else
/srv/bin/wait-for-virtualenv.sh
fi
fi
if [ "${SETUP_FRONTEND}" = "true" ];then
if [ "${RUN_YARN_INSTALL}" = "true" ];then
yarn --modules-folder /srv/node_modules/ install --frozen-lockfile
else
/srv/bin/wait-for-yarn-env.sh
fi
fi
exec "$@"