Fix python interpreter for check_local_time.py script #207
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.
https://github.com/ScaleComputing/HyperCoreAnsibleCollection/actions/runs/4686722374/jobs/8305135195#step:9:48 Here ansible_python_interpreter was not defined.
See also ansible/ansible#21311 and https://docs.ansible.com/ansible/latest/reference_appendices/special_variables.html I missed before that ansible_python_interpreter is not always defined.
We do not want to force user to tell us some valid python interpreter. Also, it would be possible that the only availble python is in venv or in /usr/local/bin (python docker images).
ansible_playbook_python looks like a suitable fallback. It is interpreter on the controller node. Our script will always run there - we never ssh to HyperCore controller.