Interactive wsl_setup no longer writes wsl.conf

That variant would only apply configs if in autoinstall.
There are no more screens available related to those settings in
wsl_setup.
Reconfiguration variant is the only one able to write that file.
This commit is contained in:
Carlos Nihelton 2022-12-16 12:16:45 +00:00
parent 0540c521fe
commit 3e04dab619
No known key found for this signature in database
GPG Key ID: 6FE346D245197E9A
1 changed files with 4 additions and 9 deletions

View File

@ -413,17 +413,12 @@ class ConfigureController(SubiquityController):
await self.create_user(root_dir, envcp)
await self.apply_locale(lang, envcp)
else:
wsl_config_update(self.model.wslconfadvanced.wslconfadvanced,
root_dir)
# update advanced config when it is in autoinstall mode
if self.app.opts.autoinstall is not None and \
self.model.wslconfadvanced.wslconfadvanced is not None:
wsl_config_update(self.model.wslconfadvanced.wslconfadvanced,
root_dir)
# update wsl.conf when it is in autoinstall mode or reconf variant.
if variant == "wsl_configuration" or \
self.app.opts.autoinstall is not None:
wsl_config_update(self.model.wslconfbase.wslconfbase, root_dir)
wsl_config_update(self.model.wslconfadvanced.wslconfadvanced,
root_dir)
self.app.update_state(ApplicationState.DONE)