Angel de Vicente
Angel de Vicente
Mmarimo
Created by Angel de Vicente on 11/2/2024 in #help-support
Serving Marimo app with Apache2 reverse proxy?
This is my setting to get it to work. In the server where Apache is running, I modify the Apache configuration file to define a VirtualHost as follows: ProxyPass /marimo http://127.0.0.1:2718/marimo nocanon ProxyPassReverse /marimo http://127.0.0.1:2718/marimo ProxyPreserveHost on # WebSocket support RewriteEngine on RewriteCond %{HTTP:Upgrade} websocket [NC] RewriteCond %{HTTP:Connection} upgrade [NC] RewriteRule ^/marimo/(.*) "ws://localhost:2718/marimo/$1" [P,L] # # Additional headers that might be useful <Location /marimo> ProxyPassReverseCookiePath / /marimo RequestHeader set X-Forwarded-Proto "http" RequestHeader set X-Forwarded-Port "80" RequestHeader set X-Forwarded-For "%{REMOTE_ADDR}s" </Location> and then I start Marimo with: marimo edit --base-url /marimo I tried without the --base-url option, but then it looks like some files are not found. Setting --base-rul to /marimo and then adding it in the URL when defining the VirtualHost all works beautifully.
6 replies
Mmarimo
Created by Angel de Vicente on 11/2/2024 in #help-support
Serving Marimo app with Apache2 reverse proxy?
I had seen that proxy setting option, but I was not sure how to get it to work. In the end, by modifying the Apache server configuration I was able to get it to work nicely (my previous attempts failed apparently because I didn't have the proxy_wstunnel module enabled)
6 replies