grimoirelab-sortinghat icon indicating copy to clipboard operation
grimoirelab-sortinghat copied to clipboard

Docker-Container: Style sheet error & Extending Documentation

Open Stefan-Buchner opened this issue 1 year ago • 2 comments

Hi all,

i am trying to set up the latest sortinghat docker container on a server of ours and access it via remote.

To do that i followed in basic your guide. As i need to access it via remote, i used the -e 'SORTINGHAT_ALLOWED_HOST=localhost,127.0.0.1,IP_ADDRESS option .

However, when accessing the webpage (Port 8000 in this case) the Browswer Extension shows the following errors: Refused to apply style from 'http://[IP-ADDRESS]:8000/identities/css/chunk-vendors.8624f262.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled. Refused to execute script from 'http://[IP-ADDRESS]:8000/identities/js/chunk-vendors.870fdbfd.js' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled. Refused to apply style from 'http://[IP-ADDRESS]:8000/identities/css/app.b1eaa349.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled. Refused to execute script from 'http://[IP-ADDRESS]:8000/identities/js/app.0a23ef75.js' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.

However, the docker outputs at the same time:

[pid: 16|app: 0|req: 1/1] [[IP-ADDRESS] () {40 vars in 801 bytes} [Thu Nov 2 08:04:00 2023] GET / => generated 851 bytes in 671 msecs (HTTP/1.1 200) 6 headers in 180 bytes (1 switches on core 0) [pid: 16|app: 0|req: 5/2] [IP-ADDRESS] () {38 vars in 723 bytes} [Thu Nov 2 08:04:00 2023] GET /identities/js/chunk-vendors.870fdbfd.js => generated 851 bytes in 10 msecs (HTTP/1.1 200) 6 headers in 180 bytes (1 switches on core 2) [pid: 16|app: 0|req: 5/3] [IP-ADDRESS] () {38 vars in 721 bytes} [Thu Nov 2 08:04:00 2023] GET /identities/css/app.b1eaa349.css => generated 851 bytes in 11 msecs (HTTP/1.1 200) 6 headers in 180 bytes (1 switches on core 3) [pid: 16|app: 0|req: 5/4] [IP-ADDRESS] () {38 vars in 703 bytes} [Thu Nov 2 08:04:00 2023] GET /identities/js/app.0a23ef75.js => generated 851 bytes in 8 msecs (HTTP/1.1 200) 6 headers in 180 bytes (1 switches on core 0) [pid: 16|app: 0|req: 5/5] [IP-ADDRESS] () {38 vars in 741 bytes} [Thu Nov 2 08:04:00 2023] GET /identities/css/chunk-vendors.8624f262.css => generated 851 bytes in 13 msecs (HTTP/1.1 200) 6 headers in 180 bytes (1 switches on core 1) [pid: 16|app: 0|req: 6/6] [IP-ADDRESS] () {38 vars in 774 bytes} [Thu Nov 2 08:04:00 2023] GET /identities/favicon-grimoirelab.ico => generated 851 bytes in 2 msecs (HTTP/1.1 200) 6 headers in 180 bytes (1 switches on core 2)

That leads me to two questions/requests:

  1. Is that an configuration error on my side (am i missing an option) or is that an SortingHat Error
  2. It would be nice to have an extended documentation of all the available options. Figuring out the SORTINGHAT_ALLOWED_HOST Option with the right , separator took me way to long. Having both a list of available options & what they do and a separated usage guide for the Dev- and Prod-Variant would be really helpful and save a lot of time for users.

Can you help me there?

Thank you very much

Stefan

Stefan-Buchner avatar Nov 02 '23 09:11 Stefan-Buchner

Thanks for reporting this. I'll have a lot at it tomorrow and I will report you back with my findings.

sduenas avatar Nov 02 '23 17:11 sduenas

Sorry for my late reponse. Busy days.

We found the problem. The --dev flag doesn't work. There's a bug with it. While we fix it, you will have to remove the flag an run an nginx image or similar to handle static files and requests to sortinghat.

sduenas avatar Nov 17 '23 16:11 sduenas