Add keyboard layout options #409
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Keyboard Layout Option
This Pull Request adds the ability to configure the keyboard layout via the GOAD shell, as well as an arg.
Added cli option:
set_keyboard_layout <layout>,<layout2>...Added arg:
goad.py --keyboard_layout <layout>,<layout2>...The problem is how to get the variables from the python script into the ansible var space. So far i see that three inventory/settings files are loaded where we could place that value:
inventoryin /ad//data/inventoryinventoryin the workspaceglobalsettings.iniAs the globalsettings.ini file would be unclean imho, as this is a place for global variables and not per-lab variables. Therefore (and because of lack of knowledge if there is a better way), i decided to inject it into the workspace inventory file with the config parser. Let me know what is best :)
Disclaimer
So far, the injection of the
keyboard_layoutwas correctly picked up by ansible and configured on my lab. However, although the registry flags were configured to use (in my case) the german keyboard layout, Windows did not switch to that layout. That problem should however be independent to this PR, as this basically only replaces the hard coded variables in theglobalsettings.ini.Screenshots: