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 instructions when using systemctl services and python virtualenv #557

Open
NuberuSH opened this issue Aug 18, 2024 · 0 comments
Open
Labels
enhancement New feature or request

Comments

@NuberuSH
Copy link

NuberuSH commented Aug 18, 2024

When using python virtual environments to install the dependencies you need to modify the ExecStart value so it uses the correct set of libraries, but this is not specified in the how to start guide, even though it is recommended in previous steps to use them.

So, the tools/turing-smart-screen-python.service file should look something like this:

...


; If you want to put the program in your home directory instead, remove 'ProtectHome=read-only' line below
WorkingDirectory=/opt/turing-smart-screen-python/

ExecStart=/opt/turing-smart-screen-python/.venv/bin/python3 main.py

; Always restart the script
Restart=always

...

Or the proper route if you have it under the $HOME directory.

Maybe for some more experienced user this is simply logical but for people who never set services in a project using virtualenvs can be quite a headache.

@NuberuSH NuberuSH added the enhancement New feature or request label Aug 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant