*** herald85 has joined #ara | 06:06 | |
*** gvincent has joined #ara | 06:36 | |
*** gvincent has quit IRC | 06:44 | |
*** logan- has quit IRC | 07:33 | |
*** logan- has joined #ara | 07:33 | |
*** gvincent has joined #ara | 08:00 | |
*** vincent- has joined #ara | 09:22 | |
*** odyssey4me has left #ara | 10:51 | |
*** dbpiv has joined #ara | 11:52 | |
*** idir__ has joined #ara | 14:16 | |
*** idir__ has quit IRC | 15:16 | |
*** idir__ has joined #ara | 15:17 | |
idir__ | hi, i'm trying to setup the new version of ara, but the interface does not show any data ( the database and the ara-api are ok) can you help me please ? | 15:20 |
---|---|---|
dmsimard | idir__: sure thing | 15:24 |
dmsimard | idir__: are you able to browse the API web interface ? | 15:25 |
dmsimard | should look like this: https://api.demo.recordsansible.org/api/v1/ | 15:25 |
idir__ | I can access the interface but no data is displayed while there is data in the database | 15:26 |
idir__ | and the API is ok, I can see the data on the interface django framework | 15:28 |
idir__ | in summary the web ara interface is displayed, the interface API django framework is also functional with the good data retrieved, but on the ara-web interface no data | 15:30 |
dmsimard | idir__: so in public/config.json, there is a configuration option that needs to be set to where the API server is hosted: https://github.com/ansible-community/ara-web/blob/master/public/config.json | 15:31 |
idir__ | yes I have set the address of the API, http: // ip: port/api/v1/ in the json file | 15:32 |
idir__ | i using ansible roles to install all the part of ara and the database | 15:34 |
dmsimard | idir__: don't add /api/v1 | 15:34 |
dmsimard | just the URL | 15:34 |
dmsimard | like the link I just provided, "apiURL": "http://localhost:8000" -- not "http://localhost:8000/api/v1" | 15:35 |
idir__ | i have the ara-web and ara-api in the same host, so I need to put localhost or the IP address? | 15:37 |
*** etienne has joined #ara | 15:38 | |
dmsimard | idir__: it depends on the address the server is listening on | 15:38 |
dmsimard | idir__: if it's listening on 127.0.0.1, you'd need to put 127.0.0.1 | 15:39 |
dmsimard | if it's listening on, say, 0.0.0.0, it can be any IP or hostname that resolves to your machine | 15:39 |
idir__ | yes it's 127.0.0.1:8000 | 15:40 |
*** spiette_ has joined #ara | 15:41 | |
*** spiette has quit IRC | 15:41 | |
dmsimard | gvincent: considering we have a proper "/" now with https://api.demo.recordsansible.org/, we should probably have an error that differentiates between "I contacted the API server but it's empty" vs "There's no API server at this destination" | 15:44 |
idir__ | with 127.0.0.1 it does not work :/ | 15:44 |
dmsimard | idir__: let me try to reproduce locally | 15:44 |
idir__ | ok | 15:45 |
idir__ | thank you for giving me all this attention :) | 15:46 |
dmsimard | gvincent: created issue as https://github.com/ansible-community/ara-web/issues/9 | 15:49 |
dmsimard | idir__: running the API server (ara-manage runserver 127.0.0.1:8000) and the web client with defaults (npm install, npm start -- localhost:3000) works for me | 15:52 |
dmsimard | idir__: how are you running the API server ? | 15:52 |
dmsimard | also, are you running the latest versions ? | 15:53 |
openstackgerrit | David Moreau Simard proposed recordsansible/ara-web master: Add a note about configuring public/config.json in the README https://review.opendev.org/661798 | 15:54 |
openstackgerrit | David Moreau Simard proposed recordsansible/ara-web master: Add a note about configuring public/config.json in the README https://review.opendev.org/661798 | 15:55 |
idir__ | dmsimard: I run it from an ansible role that uses gunicorn | 15:57 |
dmsimard | idir__: the bundled ara_api role ? | 15:58 |
idir__ | yes | 15:58 |
idir__ | and the role ara-web also | 15:59 |
dmsimard | ok, is there nginx in front ? | 15:59 |
idir__ | yes | 15:59 |
dmsimard | idir__: what linux distro ? | 16:03 |
idir__ | rhel 7 | 16:04 |
idir__ | now i have retrieved the request from the browser and I see http://127.0.0.1:8000/api/v1/playbooks (failed) | 16:04 |
openstackgerrit | David Moreau Simard proposed recordsansible/ara-web master: Fix contributors link from /openstack/ to /ansible-community/ https://review.opendev.org/661801 | 16:05 |
dmsimard | idir__: I'm not sure I follow -- it fails now but it didn't earlier ? | 16:05 |
idir__ | before there was not this query | 16:07 |
idir__ | i think i have to set the external ip address | 16:07 |
idir__ | but when i curl inside the host http://127.0.0.1:8000/api/v1/playbooks it works | 16:09 |
dmsimard | idir__: so the way this works is that your browser is the one doing API requests | 16:10 |
dmsimard | idir__: if the API server is set to 127.0.0.1, your browser will query 127.0.0.1 which won't work if the API server isn't running on your local machine | 16:11 |
idir__ | yes it's normal, now I just put the address of the machine | 16:13 |
dmsimard | idir__: slightly related, I'm interested how you got the new version of ara working on rhel 7 :) | 16:13 |
dmsimard | Did you use software collections ? | 16:13 |
*** ChanServ sets mode: +o dmsimard | 16:14 | |
idir__ | Request URL: http://192.168.226.59:8000/api/v1/playbooks Request Method: GET Status Code: 200 OK | 16:14 |
idir__ | but no data displayed oo' | 16:15 |
dmsimard | idir__: 192.168.226.59 needs to be added to ALLOWED_HOSTS and CORS_ORIGIN_WHITELIST | 16:15 |
dmsimard | well, hang on | 16:16 |
dmsimard | not ALLOWED_HOSTS since you're running off of 127.0.0.1 and that's fine | 16:16 |
dmsimard | but you might have a CORS error in your browser console | 16:16 |
idir__ | yes i have this error now | 16:17 |
dmsimard | idir__: there's a variable for that in the role https://github.com/ansible-community/ara-infra/blob/47ecb4fa1176cbe9f8a0f0e42477551df3ec5f7a/playbooks/live-demo.yaml#L13 | 16:18 |
idir__ | yes I edit in a variable file | 16:19 |
idir__ | i'm deploying changes | 16:21 |
idir__ | so i add the ip to the whitelist | 16:21 |
*** herald85 has quit IRC | 16:25 | |
idir__ | dmsimard yes it works \o/ | 16:26 |
idir__ | in summary I use nginx with a server_name, and I had to add it in the whitelist. and also in the config.json I have the address 192.168 ... | 16:28 |
openstackgerrit | David Moreau Simard proposed recordsansible/ara feature/1.0: Add missing selinux policy package for running gunicorn https://review.opendev.org/661808 | 16:28 |
dmsimard | idir__: nice job | 16:29 |
openstackgerrit | Merged recordsansible/ara-web master: Add a note about configuring public/config.json in the README https://review.opendev.org/661798 | 16:29 |
dmsimard | idir__: did you use python3 from EPEL or from software collections to run this new version ? | 16:29 |
idir__ | j'ai pas bien compris la question, mais python3 était déja installé sur la machine | 16:31 |
idir__ | I did not understand the question, but python3 was already installed on the machine | 16:31 |
dmsimard | rhel7 doesn't ship python3 by default so I was curious :) | 16:33 |
dmsimard | Thanks for trying out the beta, I've already taken a few notes and sent a few fixes :p | 16:33 |
idir__ | yes it's a symbolic link to python 3 | 16:34 |
idir__ | thank you very much, I also added to the roles / vars the RedHat os familly | 16:36 |
idir__ | il était très intéressant de comprendre tous les rôles et la personnalisation pour Redhat | 16:37 |
idir__ | it was very interesting to understand all the roles and customising for Redhat | 16:37 |
dmsimard | Merci! :) | 16:39 |
idir__ | ;) | 16:40 |
*** idir__ has quit IRC | 16:45 | |
*** etienne has quit IRC | 17:10 | |
*** etienne has joined #ara | 17:11 | |
*** irclogbot_2 has quit IRC | 17:17 | |
*** irclogbot_3 has joined #ara | 17:17 | |
openstackgerrit | Merged recordsansible/ara-web master: Fix contributors link from /openstack/ to /ansible-community/ https://review.opendev.org/661801 | 18:17 |
openstackgerrit | David Moreau Simard proposed recordsansible/ara feature/1.0: Add missing selinux policy package for running gunicorn https://review.opendev.org/661808 | 18:20 |
*** harlowja has joined #ara | 21:44 |
Generated by irclog2html.py 2.15.3 by Marius Gedminas - find it at mg.pov.lt!