forked from claudyus/LXC-Web-Panel
-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
Hi,
Seems like this version of LXC-Web-Panel doesn't support having duplicate keys in the LXC config file. Having duplicate keys are completely legal in LXC and all options are read properly (Even if duplicate).
One frequent case is when you want to mount multiple things, you're repeatedly using "lxc.mount.entry".
But right now if you have multiple mount points in the LXC configuration, the whole LXC-Web-Panel breaks after logging in.
The exception says:
[2019-01-05 17:38:36,444] ERROR in app: Exception on /home [GET]
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/Flask-1.0.2-py3.5.egg/flask/app.py", line 2292, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python3.5/dist-packages/Flask-1.0.2-py3.5.egg/flask/app.py", line 1815, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python3.5/dist-packages/Flask-1.0.2-py3.5.egg/flask/app.py", line 1718, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.5/dist-packages/Flask-1.0.2-py3.5.egg/flask/_compat.py", line 35, in reraise
raise value
File "/usr/local/lib/python3.5/dist-packages/Flask-1.0.2-py3.5.egg/flask/app.py", line 1813, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python3.5/dist-packages/Flask-1.0.2-py3.5.egg/flask/app.py", line 1799, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/usr/local/lib/python3.5/dist-packages/lwp-0.10b1-py3.5.egg/lwp/utils.py", line 96, in new_handler
return handler(*args, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/lwp-0.10b1-py3.5.egg/lwp/views/main.py", line 49, in home
'settings': lwp.get_container_settings(container, status),
File "/usr/local/lib/python3.5/dist-packages/lwp-0.10b1-py3.5.egg/lwp/__init__.py", line 233, in get_container_settings
config.readfp(normalized)
File "/usr/lib/python3.5/configparser.py", line 760, in readfp
self.read_file(fp, source=filename)
File "/usr/lib/python3.5/configparser.py", line 715, in read_file
self._read(f, source)
File "/usr/lib/python3.5/configparser.py", line 1089, in _read
fpname, lineno)
configparser.DuplicateOptionError: While reading from '<???>' [line 28]: option 'lxc.mount.entry' in section 'DEFAULT' already exists
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels