nginx with ngx_http_sub_module for reverse proxy

  • Hello,


    i tried to use reverse proxy with nginx to access some websites in my local network.


    But there seems to be a problem when websites uses non relative urls in their htmlcode (like "src='/extjs/...'")
    So nginx would search that in his local root directory.
    If found out that nginx can modify the html code of the websites sent to the browser by using "sub filter".


    The ngx_http_sub_module module is a filter that modifies a response by replacing one specified string by another.
    This module is not built by default, it should be enabled with the --with-http_sub_module configuration parameter.


    Propaply that seems not enabled in the nginx plugin for OMV.
    Is ist possible to build an nginx plugin with that option?


    Would be very nice.
    Thank you

    • Offizieller Beitrag

    The ngnix plugin is just a front end to add ngnix server blocks configurations. The ngnix binary/package is provided by the underlying Linux distribution Debían. You will have to download the src of the Debian ngnix package, modify the compiling flag and built it yourself to have that feature enabled.
    Omvextras will not ship an ngnix binary since is the core http engine used by Omv.

  • Ok thank you.
    Then I have to try it.
    Something to be considered? Are any special other flags set for omv?
    Is the default .configure



    What happens with modified nginx if updates were installed via omv-webinterface?


    Edit:
    using nginx -V shows that ngx_http_substitutions_filter_module is already included.
    Should be possible to replace the relative urls with that. I'm just trying

  • Did you finally solve this?


    Can't figure it out.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!