Openhab Sitemap Pictures publish OH-Cloud

Hi,

I am running OH v2 on a Windows Host. Everything is working. I have changed my camera control. So these are now collected from a surveillance software and I can show them on a good and fast way via item URL in the sitemap.

This is only possible if I am accessing the OH sitemap internally. Externally without VPN the images will not showed in this way. If I change the IP from the local surveillance station to the local IPs of the cameras directly I can see them also via internet in the sitemap.

The question is now if there is an easy way to store the image (maybe every second) in an item and publish this item aswell so that I can have access to it also from outside?

Thanks

Using what widget? can we see?

Image sitemap widget has a baby proxy and refresh functions.

Its just a frame with the image in it:
image

Do you mean this?

Yep. Here’s one of mine that I can see from off-site. (OH2.5 on Win)

Image label="Yard Cam10" url="http://192.168.1.50:80/mobile/channel10.jpg" refresh=16500

and it updates by refresh.

What does one of those look like? I’m reading this as meaning “It works fine except for this URL (the station)”.

Hi,

if I use this link:

Image url="http://192.168.0.85/action/snap?cam=0&user=<user>&pwd=<password>" refresh=1000

I can see the picture also from outside! This is also an internal IP from my home network. If I switch to this line:

Image url="http://192.168.0.165:8090/grab.jpg?oid=1&size=1280x720" refresh=1000

It shows nothing from outside. The difference in the IP address is, that the 0.85 points directly to the camera. The 0.165 is the device where Openhab is running on (localhost).

I have changed to your suggestion:

Image label="Test" url="http://192.168.0.165:8090/grab.jpg?oid=1&size=1280x720" refresh=16500

But still no picture from outside. But its nearly the same I have already…

And there is a port number involved. That shouldn’t make any difference, of course. In both cases the viewer should be trying to fetch an image from a proxy servlet in openHAB using a URL something like
http://youropenhab:8080/proxy?sitemap=default.sitemap&widgetId=01020000&t=1633686921137
and the URL you put in your widget completely hidden.

What do yours look like? (inspect at the browser)

this is the link for the URL which is reachable from outside:

http://192.168.0.165:8080/proxy?sitemap=house.sitemap&widgetId=03020000&t=1642163846691

And this one is not reachable from outside:

http://192.168.0.165:8080/proxy?sitemap=house.sitemap&widgetId=03020001&t=1642163955682

So its nearly the “same”…

Well, in reality both those links are surely ‘reachable’ but you don’t get the return picture you expect. What do you get when pasting hem directly in browser address bar? It’s going to be one of those silly things like jpg/jpeg difference. The images have been supplied from different sources.

If that really means the station image widget works on local internet, then the proxy servlet is happy with it. What is different remotely? The browser that you are using, or the content allowed to pass through a firewall or reverse proxy?

I am accessing with the OpenHAB App from iOS. In this app the local IP and the OpenHAB credentials are inserted.
If the local one is not reachable the app changes to the myopenhab access. Every item, widget and so on is working with this way except these camera pictures!

Is there maybe another option with a rule or something like this that I can store the current image in an item?