Open
Description
Component: solutions, scripts
What happened:
Trying to import a Solution already present with a different archive (in the same version), we end up with a not user friendly Salt error:
2021-02-11 09:38:39,311 [salt.state :3607][CRITICAL][27035] Rendering SLS 'metalk8s-2.6.0:metalk8s.solutions.available' failed: while constructing a mapping
in "<unicode string>", line 6, column 1
found conflicting ID 'Mountpoint for Solution hyperdrive 0.2.2 exists'
in "<unicode string>", line 49, column 1
What was expected:
The script bails out early with a nice and clear error message.
Steps to reproduce:
- Import a solution ISO
- Make a copy of it
- Import this copy
Resolution proposal (optional):
Check the content of the archive in metalk8s_solutions.configure_archive
Salt module and exit with a clear error message if there already is an archive providing the same "solution name" + "version" couple.