afkiwers / inventree_kicad

KiCad EDA conform API endpoint for KiCad's parts library tool. This plugin provides metadata only and requires matching symbol and footprint libraries within the KiCad EDA.
MIT License
38 stars 8 forks source link

build_absolute_uri with HTTPS #83

Closed DesertLion1 closed 8 months ago

DesertLion1 commented 9 months ago

Hello to everyone,

my InvenTree installation is running behind an nginx reverse proxy with https. The X-Forwarded-Proto header is configured and https works properly throughout InvenTree. However, the absolute URIs inventree_kicad generates do not seem to respect this setting and are all only http://

For instance, the request to https://my-inventree.example/plugin/kicad-library-plugin/v1/ returns {"categories":"http://my-inventree.example/plugin/kicad-library-plugin/v1/categories/","parts":"http://my-inventree.example/plugin/kicad-library-plugin/v1/parts/"}

Any ideas what is missing?

inventree_kicad: 1.3.16 InvenTree: 0.13.5 Django: 3.2.23

Regards Stefan

SchrodingersGat commented 8 months ago

@DesertLion1 is Nginx rewriting the https so that the InvenTree server is (internally) seeing a http request?

Also, do you have the INVENTREE_SITE_URL environment variable set?

afkiwers commented 8 months ago

@DesertLion1 I assume you fixed the problem? I will close this issue for now as we haven't heard back from you.

Feel free to reopen it at any time.