diff options
Diffstat (limited to 'backend/main.py')
| -rw-r--r-- | backend/main.py | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/backend/main.py b/backend/main.py index c48ad752..a2ac008a 100644 --- a/backend/main.py +++ b/backend/main.py @@ -19,8 +19,7 @@ from aiohttp_jinja2 import setup as jinja_setup # local modules from browser import PluginBrowser from helpers import (REMOTE_DEBUGGER_UNIT, csrf_middleware, get_csrf_token, - get_home_path, get_homebrew_path, get_user, - get_user_group, set_user, set_user_group, + get_home_path, get_homebrew_path, get_user, get_user_group, stop_systemd_unit, start_systemd_unit) from injector import get_gamepadui_tab, Tab, get_tabs, close_old_tabs from loader import Loader @@ -28,18 +27,11 @@ from settings import SettingsManager from updater import Updater from utilities import Utilities -# Ensure USER and GROUP vars are set first. -# TODO: This isn't the best way to do this but supports the current -# implementation. All the config load and environment setting eventually be -# moved into init or a config/loader method. -set_user() -set_user_group() USER = get_user() GROUP = get_user_group() -HOME_PATH = "/home/"+USER -HOMEBREW_PATH = HOME_PATH+"/homebrew" +HOMEBREW_PATH = get_homebrew_path() CONFIG = { - "plugin_path": getenv("PLUGIN_PATH", HOMEBREW_PATH+"/plugins"), + "plugin_path": getenv("PLUGIN_PATH", path.join(HOMEBREW_PATH, "plugins")), "chown_plugin_path": getenv("CHOWN_PLUGIN_PATH", "1") == "1", "server_host": getenv("SERVER_HOST", "127.0.0.1"), "server_port": int(getenv("SERVER_PORT", "1337")), |
