Geonovum / ogc-api-testbed

OGC API Testbed Template - Stable
https://apitestbed.geonovum.nl
GNU General Public License v3.0
4 stars 4 forks source link

Force Ansible scripts to use Python3 #45

Closed justb4 closed 2 years ago

justb4 commented 2 years ago

This came up when using this repo as Template for a EC-JRC instance at https://jrc.map5.nl. The VM uses Ubuntu 21.04. The Python defaults did not work. Calling python was using Python 2, which is still the default. To force Python3 we adapted the Inventory config file, here prod.yml to read:

ogcapijrc:
  hosts:
    OGCAPIJRC:
       ansible_port: ...
       ansible_host: jrc.map5.nl
       ansible_user: ...
       ansible_python_interpreter: /usr/bin/python3

Line added is ansible_python_interpreter: /usr/bin/python3.