paukstelis / octoprint_deploy

Bash script for rapid deployment of multiple octoprint instance on a single machine
MIT License
390 stars 39 forks source link

possible to install/run as non-login service user #103

Open zerog2k opened 11 months ago

zerog2k commented 11 months ago

currently, it seems it wants to run only as a user, and only installed from sudo with that user resulting octoprint is running with this non-root user but this requires it to use a real user which has login/shell privilege, and consequently sudo access itself. If possible I'd rather run octoprint with an unprivileged user which cannot login (e.g. shell = /sbin/nologin, etc) and cannot sudo. I wonder if there is a way to run the script as root, but specify either some service user to use, or create, e.g. octoprint

paukstelis commented 11 months ago

No plans to include that. A user makes things more predictable with respective to paths where things are installed.

fake-name commented 11 months ago

Uh, none of the things you list are precluded by a non-login user.

Also, having everything as a subdirectory of $HOME is less predictable then using a purpose-specific directory like /www/octoprint or similar. What if $HOME is somewhere weird?

paukstelis commented 11 months ago

Even if it is somewhere weird, the shell knows where it is. That's the point of $HOME is a variable.