File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -59,6 +59,7 @@ ovos_config_virtualenv_directories:
5959ovos_config_geoip_url : " {{ ovos_installer_geoip_url }}"
6060ovos_config_geoip_enabled : " {{ ovos_installer_geoip_enabled | default(false) }}"
6161ovos_config_geoip_timeout : 5
62+ ovos_config_mark2_network_tests_ip_url : " {{ ovos_installer_mark2_network_tests_ip_url }}"
6263ovos_config_mycroft_conf_relpath : " {{ '.config/mycroft' if ovos_installer_method == 'virtualenv' else 'ovos/config' }}"
6364ovos_config_mycroft_conf_mode : " 0600"
6465ovos_config_system_unit : " {{ ovos_installer_system_unit }}"
Original file line number Diff line number Diff line change 100100 "host": "{{ '0.0.0.0' if ovos_installer_method == "containers" else '127.0.0.1' }}",
101101 "max_msg_size": 25
102102 },
103+ {% if 'tas5806' in ovos_installer_i 2c_devices %}
104+ "network_tests": {
105+ "ip_url": "{{ ovos_config_mark2_network_tests_ip_url }}"
106+ },
107+ {% endif %}
103108 "PHAL": {
104109 "admin": {
105110 "ovos-PHAL-plugin-system": {
119124 }
120125 },
121126 "ovos-phal-plugin-ipgeo": {
122- "enabled": false
127+ "enabled": true
123128 }
124129{% endif %}
125130 }{% if ovos_installer_usage_telemetry | bool %} ,
Original file line number Diff line number Diff line change @@ -136,6 +136,7 @@ ovos_installer_telemetry: "{{ ovos_installer_usage_telemetry | bool }}"
136136ovos_installer_run_ovos_config : false
137137ovos_installer_geoip_enabled : false
138138ovos_installer_geoip_url : " https://ipapi.co/json/"
139+ ovos_installer_mark2_network_tests_ip_url : " https://ifconfig.me/ip"
139140ovos_installer_system_unit : " metric"
140141ovos_installer_temperature_unit : " celsius"
141142ovos_installer_precipitation_unit : " mm"
Original file line number Diff line number Diff line change @@ -265,16 +265,22 @@ function setup() {
265265 assert_failure
266266}
267267
268- @test " mycroft_conf_disables_ipgeo_phal_plugin_for_mark2 " {
268+ @test " mycroft_conf_enables_ipgeo_phal_plugin_and_sets_mark2_ip_lookup_url " {
269269 local conf_file=" ansible/roles/ovos_config/templates/mycroft.conf.j2"
270270
271271 run grep -F -q " {% if 'tas5806' in ovos_installer_i2c_devices %}" " $conf_file "
272272 assert_success
273273
274+ run grep -F -q " \" network_tests\" : {" " $conf_file "
275+ assert_success
276+
277+ run grep -F -q " \" ip_url\" : \" {{ ovos_config_mark2_network_tests_ip_url }}\" " " $conf_file "
278+ assert_success
279+
274280 run grep -F -q " \" ovos-phal-plugin-ipgeo\" : {" " $conf_file "
275281 assert_success
276282
277- run bash -c " grep -A4 -F -- \"\\\" ovos-phal-plugin-ipgeo\\\" : {\" \" $conf_file \" | grep -q -- \"\\\" enabled\\\" : false \" "
283+ run bash -c " grep -A4 -F -- \"\\\" ovos-phal-plugin-ipgeo\\\" : {\" \" $conf_file \" | grep -q -- \"\\\" enabled\\\" : true \" "
278284 assert_success
279285}
280286
You can’t perform that action at this time.
0 commit comments