diff --git a/scripts/add-aliases.sh b/scripts/add-aliases.sh index 5cfbc96..b0b1f55 100755 --- a/scripts/add-aliases.sh +++ b/scripts/add-aliases.sh @@ -165,7 +165,8 @@ function fullreset(){ function alembic(){ ex -e SQL_USE_ALEMBIC_USER=yes -e SQL_PASSWORD=superroot -e SQLALCHEMY_POOL_RECYCLE=3600 ${1} \ - bash -c 'cd /src && python3 manage.py db '"${@:2}"'' + bash -c 'cd /opt/app-root/src && [ -d "$VENV_DIR" ] && source $VENV_DIR/bin/activate; + python3 manage.py db '"${@:2}"'' } function devenv-help(){