How to hide the Z-Way url?

Discussions about RaZberry - Z-Wave board for Raspberry computer
Post Reply
McD
Posts: 17
Joined: 28 Mar 2013 14:15

How to hide the Z-Way url?

Post by McD »

I am trying to hide the "ugly" Z-Way URL with Port 8083 with a nice https Apache proxy solution. (Apache2-ssl runs on the same linux box)

This usally works fine with all web apps.

The apache2-ssl config part is:


ProxyRequests Off

Order deny,allow
Allow from all

ProxyPass /zway/ http://localhost:8083/ keepalive=on
ProxyPassReverse /zway/ http://localhost:8083/

Unluckily this gives me the already well known "Sorry, server has not completely started yet..." (see http://en.z-wave.me/content/sorry-serve ... tarted-yet) error message.
If I use the same browser and direct it to http://_ip address_:8083 all works fine. So it has this time nothing to do with the config.

My guest is that the extensive use of javascript causes this errormessage.

Can you please help and give me a hint, how to hide the z-way program behind the proxy.
(Changing just the port of the z-way software would not do it, since my proxy shall do ssl and authentication)

Thank you
User avatar
PoltoS
Posts: 7571
Joined: 26 Jan 2011 19:36

Please use Debug JS Console

Post by PoltoS »

Please use Debug JS Console of your browser to get more info. I suppose you do not proxy POST requests or the response is mangled. The error means that minimal data in /ZWaveAPI/Data/0 is absent (usually means the server has not started yet, but not in your case, where you mangle packets).
McD
Posts: 17
Joined: 28 Mar 2013 14:15

Ok...

Post by McD »

Thanks for the tip.
Indeed with a little console work I found that the config Apache2 needed to be enhanced to this:

ProxyRequests Off

Order deny,allow
Allow from all


ProxyPass /zway/ http://localhost:8083/ keepalive=on
ProxyPassReverse /zway/ http://localhost:8083/

ProxyPass /ZWaveAPI/ http://localhost:8083/ZWaveAPI/ keepalive=on
ProxyPassReverse /ZWaveAPI/ http://localhost:8083/ZWaveAPI/

ProxyPass /config/ http://localhost:8083/config/ keepalive=on
ProxyPassReverse /config/ http://localhost:8083/config/

ProxyPass /pics/ http://localhost:8083/pics/ keepalive=on
ProxyPassReverse /pics/ http://localhost:8083/pics/

Now it works very good.

But it would have been nice just to have one ProxyPass directive in the config.

Can you please add a context config switch into your software, telling it which prefix for the local part of the URL it should use. This would make it much easier.
User avatar
PoltoS
Posts: 7571
Joined: 26 Jan 2011 19:36

Please expmain your idea in

Post by PoltoS »

Please expmain your idea in more details:
> Can you please add a context config switch into your software,
> telling it which prefix for the local part of the URL it should use.
> This would make it much easier.
User avatar
PoltoS
Posts: 7571
Joined: 26 Jan 2011 19:36

This is a good idea in

Post by PoltoS »

This is a good idea in conjunction with authentication and SSL. But why not Ngnix? It is faster and smaller.

If you have already done this using Apache or Ngnix, please share. We are thinking if we need to implement SSL and Basic Auth in our solution, or use proxy for this.
Post Reply