[web] fix -> not informing the env vars during the launch process

This commit is contained in:
Vinicius Moreira
2020-08-20 14:37:49 -03:00
parent 912550e0ed
commit c4e20e17c7
2 changed files with 4 additions and 2 deletions

View File

@@ -80,6 +80,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- minor fixes
- Snap
- some environment variables are not available during the common operations (install, upgrade, downgrade, uninstall, launch)
- Web
- some environment variable are not available during the launch process
- UI
- crashing when nothing can be upgraded
- random C++ wrapper errors with some forms due to missing references

View File

@@ -26,7 +26,7 @@ from bauh.api.abstract.model import SoftwarePackage, CustomSoftwareAction, Packa
from bauh.api.abstract.view import MessageType, MultipleSelectComponent, InputOption, SingleSelectComponent, \
SelectViewType, TextInputComponent, FormComponent, FileChooserComponent, ViewComponent, PanelComponent
from bauh.api.constants import DESKTOP_ENTRIES_DIR
from bauh.commons import resource, user
from bauh.commons import resource
from bauh.commons.config import save_config
from bauh.commons.html import bold
from bauh.commons.system import ProcessHandler, get_dir_size, get_human_size_str, SimpleProcess
@@ -949,7 +949,7 @@ class WebApplicationManager(SoftwareManager):
return True
def launch(self, pkg: WebApplication):
subprocess.Popen(pkg.get_command(), shell=user.is_root())
subprocess.Popen(args=[pkg.get_command()], shell=True, env={**os.environ})
def get_screenshots(self, pkg: SoftwarePackage) -> List[str]:
pass