Open achimnol opened 4 years ago
Or, we could execute the post-install script whenever the manager server or the CLI starts. (For the CLI, we could ask the user to confirm the upgrade operation. If the server is running already, we also should warn the users to restart it.)
Let's add a post-install script to our manager which performs:
alembic upgrade head
orbackend.ai mgr schema oneshot
(if first install)migrations
directory)This must be executed after all of the following commands:
pip install -U backend.ai-manager
pip install -U -e .
in the working copypython setup.py develop
Currently there is no simple way to add pre/post-install scripts in Python wheels. (Adding codes around
setup()
or settingcmdclass
does not seem to work for all cases above...) We need to figure out how to do this first.┆Issue is synchronized with this Asana task by Unito