Hello, I have questions about the images displayed in Ignition Perspective. I am using Python 3 to generate an image that I would like to place in Perspective. To do this, I place it in the Inductive Automation\Ignitionwebserver\webapps\main directory so that it can be referenced in the image source component.
When I share the image and refer to it by path everything works fine:
However, this happens when Perspective is run outside the gateway. On the server Perspective displays the image correctly:
I have also tried replacing the localhost address with the gateway IP address but I am also encountering a display problem. This happens on both the gateway and other computers connected to it. Source with gateway IP address doesn't seem to work, there is no preview both designer and in the fired up SCADA in the browser.
However, displaying the graphics in another window after right-clicking in the browser works fine everywhere:
Well, localhost is definitely never going to work anywhere outside the gateway machine, because localhost is always local, by definition. Get your IP address or hostname working, and use a designer that is not on the gateway. (Look for firewall issues--that is the most common reason the machine's external IP isn't reachable.)
Sure "localhost" won't work however also naming by IP and I think I found the cause but do you know maybe how to solve it?
10:25:15.039 [Browser Thread: 59744] WARN Perspective.Designer.Workspace - level: WARNING
message: "Mixed Content: The page at \'https://<IP>:8043/data/perspective/design\' was loaded over HTTPS, but requested an insecure element \'http://<IP>:8088/Files/image.jpg\'. This request was automatically upgraded to HTTPS, For more information see https://blog.chromium.org/2019/10/no-more-mixed-messages-about-https.html"
Is it possible to connect to webserver resources using https?
Obligatory "even if you get this working, it's not supported" post.
That directory happens to work at this time, but it was never intended to be a long-term solution and we do not recommend you use it in this capacity. At this time the only officially supported routes for displaying images are:
With the WebDev module, yes. If you don't want to pay for a WebDev license, you could put those files into a database and use my free Blob Server instead. But the "main" folder has real problems (cannot change or delete anything once served until a gateway restart) due to Jetty implementation details. Works by accident, and is utterly unsupportable.