Jump to content
We've recently updated our Privacy Statement, available here ×

Error while running jasperserver behind a Nginx reverse proxy.


prageethpmplus

Recommended Posts

Hi,

i have several instances of dockerized jasperserver instances. They are running on the same server on different port.
On the same server i also has a nginx server running too. 

i have following settings on Dockerfile to host http://xx.xx.xx.xx/ instead of http://xx.xx.xx.xx/jasperserver.

Dockerfile

RUN rm -rf /usr/local/tomcat/webapps/ROOT
RUN mv /usr/local/tomcat/webapps/jasperserver /usr/local/tomcat/webapps/ROOT
RUN rm -r /usr/local/tomcat/work

web.xml

<context-param>
        <param-name>webAppRootKey</param-name>
        <param-value>ROOT.root</param-value>
</context-param>

My environments are as follows.

 

InstanceEnvironment
http://xx.xx.xx.xx:13425dev
http://xx.xx.xx.xx:13427qa
http://xx.xx.xx.xx:13429ops


So when i point to http://xx.xx.xx.xx:13429/ . i can login to jasperserver with credentiuals.

My next step is to access jasperver via nginx.

This is my location block for ops env.

location /reporting-ops/ {

        proxy_set_header    Host $host;
        proxy_set_header X-Forwarded-Proto $scheme;
        rewrite ^/reporting-ops/(.*) /$1 break;
        proxy_redirect off;
        proxy_pass http://xx.xx.xx.xx:13429/$1;
}

when i type http://xx.xx.xx.xx/reporting-ops/ on the browser i get redirected. (Please see image)

i have done same kind of url rewriting for other appl;ications and they work fine. So i assume this must be something to 
do with jasperserver.

 

capture_j1.png.af77d6385aee7e76aae50bf83228e5dd.png

Thank you Very much.

 

 

 

Link to comment
Share on other sites

  • 4 weeks later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...