Closed zly20129 closed 1 month ago
My InvenTree is deployed in Ubuntu 20.04 on a VMware 15.0 workstation platform, so I can package the whole system and send it to you if you gents want to know the exact problem.
@zly20129 two questions to get started here:
1 - Does the system work when you return to using http
? Or is it broken once you attempt https
?
2 - You also change the IP address. Does it work if you use https://inventree.localhost
?
@zly20129 two questions to get started here:
1 - Does the system work when you return to using
http
? Or is it broken once you attempthttps
? 2 - You also change the IP address. Does it work if you usehttps://inventree.localhost
?
Understood to access via another computer you'll need to specify an IP. But, please try (on the same system where http://inventree.localhost
is accessible) if the https://inventree.localhost
works. Trying to eliminate potential differences.
Understood to access via another computer you'll need to specify an IP. But, please try (on the same system where
http://inventree.localhost
is accessible) if thehttps://inventree.localhost
works. Trying to eliminate potential differences.
This domain name you provided is accessible via HTTPS on the computer running the server.
Understood to access via another computer you'll need to specify an IP. But, please try (on the same system where
http://inventree.localhost
is accessible) if thehttps://inventree.localhost
works. Trying to eliminate potential differences.
This pitiful translation software, it causes some ambiguity. What this sentence was supposed to mean: I just, tried to install InvenTree on another Ubuntu 20.04 desktop system (running on a VM virtual machine), and in the Firefox browser it came with, it was possible to access it via https://inventree.localhost这个域名访问. However, after setting it to HTTPS:// IP, neither the HTTPS:// IP address nor HTTPS://127.0.0.1 are accessible via HTTPS. But setting it to HTTP://IP doesn't have this problem. ----"I tried installing InvenTree on another Ubuntu 20.04 desktop VM and it was accessible via this domain, but after setting the ip, neither the ip address nor 127.0.0.1 was accessible via HTTPS, although setting it to an HTTP IP was fine."
@zly20129 this might be a limitation of the HTTPS certificates when running against a bare IP, rather than a hostname.
Apparently letsencrypt (which is what we use for certs, via our caddy container) doesn't issue certificates for bare IP addresses (whereas they will for a domain name, even if it is self-signed).
So.. that may be the reason that your browser is throwing an error, and is not something that we can address on our end. The combination of "bare" IP address and HTTPS is maybe not possible.
@zly20129 this might be a limitation of the HTTPS certificates when running against a bare IP, rather than a hostname.
Apparently letsencrypt (which is what we use for certs, via our caddy container) doesn't issue certificates for bare IP addresses (whereas they will for a domain name, even if it is self-signed).
So.. that may be the reason that your browser is throwing an error, and is not something that we can address on our end. The combination of "bare" IP address and HTTPS is maybe not possible.
Is there any way, then, to avoid the problem of using a bare IP setup that prevents the browser from opening? 那有没有什么方式,可以避免采用裸IP设置导致浏览器无法打开的问题? I don't think the point of this issue is the bare IP address, the heart of the issue is how to make it possible for a server to serve devices on a LAN via HTTPS. 我认为这个问题的重点并非是裸IP地址,问题的核心在于如何让服务器可以通过HTTPS的方式为局域网的设备提供服务。 This is because if you don't set it up in the IP way and use the domain name setting. 因为如果不用IP的方式设置,使用域名设置的话。 This means that the server's web interface can only be opened on the machine on which it is deployed, and all devices on the LAN cannot access the web management interface over the network. 这就意味着服务器的网络界面只能在部署它的那台机器上打开,局域网中的所有设备都无法通过网络访问网络管理界面。
This issue seems stale. Please react to show this is still important.
Please verify that this bug has NOT been raised before.
Describe the bug*
For the source of the question, see!7723 InvenTree 0.15.6 can't call the camera from ipad/iphone safari browser in website. I couldn't call the camera by way of a web page, and the developer told me that I had to use HTTPS access in order to do so, so I started setting up HTTPS, but it never worked.
Steps to Reproduce
For more information, please refer to!7744 How do I set up HTTPS web access? I copied the following steps from the responses to the discussion.
For this reply I'll try to change to use HTTPS access and record all actions and logs (usernames and passwords I'll override with question marks).
Expected behaviour
Successfully set up HTTPS access to call the camera.
Deployment Method
Version Information
Version Information:
InvenTree-Version: 0.15.6 Django Version: 4.2.14 Commit Hash: 23a9485 Commit Date: 2024-07-23
Database: postgresql Debug-Mode: False Deployed using Docker: True Platform: Linux-5.4.0-190-generic-x86_64-with Installer: DOC
Active plugins: [{'name': 'InvenTreeBarcode', 'slug': 'inventreebarcode', 'version': '2.0.0'}, {'name': 'InvenTreeCoreNotificationsPlugin', 'slug': 'inventreecorenotificationsplugin', 'version': '1.0.0'}, {'name': 'InvenTreeCurrencyExchange', 'slug': 'inventreecurrencyexchange', 'version': '1.0.0'}, {'name': 'InvenTreeLabel', 'slug': 'inventreelabel', 'version': '1.0.0'}, {'name': 'InvenTreeLabelMachine', 'slug': 'inventreelabelmachine', 'version': '1.0.0'}, {'name': 'InvenTreeLabelSheet', 'slug': 'inventreelabelsheet', 'version': '1.0.0'}, {'name': 'DigiKeyPlugin', 'slug': 'digikeyplugin', 'version': '1.0.0'}, {'name': 'LCSCPlugin', 'slug': 'lcscplugin', 'version': '1.0.0'}, {'name': 'MouserPlugin', 'slug': 'mouserplugin', 'version': '1.0.0'}, {'name': 'TMEPlugin', 'slug': 'tmeplugin', 'version': '1.0.0'}, {'name': 'IPNGenerator', 'slug': 'ipngen', 'version': '0.1'}]
Please verify if you can reproduce this bug on the demo site.
Relevant log output