-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Description
pip install . now works, which suggests we can publish to pypi soon.
But currently a successful pip install requires sudo. This is bad for all sorts of reasons.
The only big obstacles I know off the top of my head is:
- the dbbindings.py script needs to be place in /usr/lib/cgi-bin. This is only necessary for a subset of bookworms, anyway: some people will use a flask server, or the bookworm serve method, and so don't need to hit their system files at all. Rather than happening in the core install, there should be a new command called
bookworm config apache2that parcels out that script for those who want apache to handle their API calls over port 80. - There are various other situations in which an interactive or non-interactive script will ask for root access. (For example, to modify the file at
/etc/mysql/my.cnf; or for that new apache2 call.) Typically this happens through bookworm invoking itself on the command line through a subprocess. If bookworm isn't installed in the root user's path, these might fail. This is a particular pain when things happen like a virtualenv handling python installation. - Similarly to 2: when running the API through Apache, typically the user invoking python is not the user who installed bookworm. (It's
www-dataorhttpdor something like that). So that user also needs bookworm in their pythonpath.
The solution to 1 is easy. For 2 and 3, it is necessary to install bookworm separately for root and for the username, or to perform some gymnastics on various PYTHONPATH variables.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels