logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Webcheck Docker and Apache
Author
emeric



Joined: 08 Apr 2024
Posts: 2
Location: Belgium

PostPosted: Mon 08 Apr '24 10:51    Post subject: Webcheck Docker and Apache Reply with quote

Hi,

Seems like I need your help to deploy this project on my side.
The current configuration is as below
Ubuntu
Apache2
Docker

Here is what i did
sudo docker pull lissy93/web-check
sudo docker run -p 3000:3000 lissy93/web-check

I can access webcheck by using the following url (for example):
https://mysite.com and the below configuration :
RewriteCond %{HTTP:Upgrade} =websocket [NC]

RewriteRule /(.) ws://1.2.3.4:3000/$1 [P,L]
RewriteCond %{HTTP:Upgrade} !=websocket [NC]
RewriteRule /(.) http://1.2.3.4:3000/$1 [P,L]

But I would like to acces webcheck by https://mysite.com/webcheck

So I adapted the apache configuration with

proxypass /webcheck http://1.2.3.4:3000/
RewriteCond %{HTTP:Upgrade} =websocket [NC]
RewriteRule /webcheck/(.) ws://1.2.3.4:3000/$1 [P,L]
RewriteCond %{HTTP:Upgrade} !=websocket [NC]
RewriteRule /webcheck/(.) http://1.2.3.4:3000/$1 [P,L]
ProxyPassReverse /webcheck http://1.2.3.4:3000/

But it doesnt work. Always a 404 not found issue.
Do you have any clue of how to make it works regarding my configuration?
Thanks a lot!
Back to top
tangent
Moderator


Joined: 16 Aug 2020
Posts: 348
Location: UK

PostPosted: Tue 09 Apr '24 12:01    Post subject: Reply with quote

I've tried setting up Webcheck under Ubuntu/Docker as per your post, to take a look at your problem.

If you look at the client browser traffic when loading, not to mention analyzing a site, you'll realise the package uses many URL paths below the site root, e.g.
    /static
    /*.png - (assorted PNG image files below the site root)
    /api
    /results
    etc
I've tried using mod_rewrite to direct the appropriate requests to /webcheck, and equally mod_substitute to edit some of the response bodies to add a /webcheck prefix where appropriate; all to no avail.

You may wish to persevere, but I don't believe it will be easy to proxy the entire site functionality away from the site root.
Back to top
emeric



Joined: 08 Apr 2024
Posts: 2
Location: Belgium

PostPosted: Wed 10 Apr '24 9:53    Post subject: Reply with quote

Same thing I noticed.
Thank a lot for your time.

Subject closed
Back to top


Reply to topic   Topic: Webcheck Docker and Apache View previous topic :: View next topic
Post new topic   Forum Index -> Apache