Apache Reverse Proxy with Wildfly?Reverse proxy apache to weblogic problemHow to Proxypass on Apache?Apache...

Is divide-by-zero a security vulnerability?

How to visualize a Cayley graph in this style?

Are small insurances worth it

Why is this code uniquely decodable?

Reason Why Dimensional Travelling Would be Restricted

Is there a frame of reference in which I was born before I was conceived?

Why do members of Congress in committee hearings ask witnesses the same question multiple times?

What are these green text/line displays shown during the livestream of Crew Dragon's approach to dock with the ISS?

How to remove lines while keeping individual rows visible on a tablet

How to satisfy a player character's curiosity about another player character?

The change directory (cd) command is not working with a USB drive

Sometimes a banana is just a banana

Meth dealer reference in Family Guy

When does inspiration across artforms become plagiarism

When was drinking water recognized as crucial in marathon running?

Which aircraft had such a luxurious-looking navigator's station?

Find the next monthly expiration date

What is the difference between throw e and throw new Exception(e)?

What is better: yes / no radio, or simple checkbox?

POVM three-qubit circuit for symmetric quantum states

Contradiction with Banach Fixed Point Theorem

What am I? I am in theaters and computer programs

Make me a metasequence

As a new poet, where can I find help from a professional to judge my work?



Apache Reverse Proxy with Wildfly?


Reverse proxy apache to weblogic problemHow to Proxypass on Apache?Apache reverse proxy root with jbossApache Reverse Proxy setting for site having Spring SecurityReverse-Proxy failsBasic auth Apache with TomcatHow to reverse proxy https with lighttpd?Setting up an Apache forward proxy with 2-way SSL with certificate CN check failsTrying to use Apache 2.4 ReWriteRule in a reverse proxy from / to /repoApache https to http proxy: Backend redirects to plain http













1















I have both Apache and Wildfly installed on a Ubuntu 14.04 system. Now I'd like to make Wildfly (locally http://localhost:8080) accessible from Apache (http://webserver/wildfly). How would I have to do that?



Sofar, I've enabled the two mods: proxy and proxy_http.
And I've added at the end of the document /etc/apache2/apache2.conf:



ProxyRequests off
ProxyPass /wildfly/ http://localhost:8080/
ProxyPassReverse /wildfly/ http://localhost:8080/


EDIT:



Now half of it works, but the paths are not transformed right. The path to one of my apps running on Wildfly is:



http://webserver/wildfly/testproj/Index.xhtml



But all links on its page are processed like this:



http://webserver/testproj/Page1.xhtml
http://webserver/testproj/Page2.xhtml
http://webserver/testproj/Page3.xhtml


rather than this:



http://webserver/wildfly/testproj/Page1.xhtml
http://webserver/wildfly/testproj/Page2.xhtml
http://webserver/wildfly/testproj/Page3.xhtml


If I run Wildfly locally, everything works fine. This lets me believe that there must be an error in the Apache Reverse Proxy configuration. Is that right? What must I do to have Apache parse the right addresses / links?










share|improve this question
















bumped to the homepage by Community 6 hours ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
















  • What says netstat -anp | grep 8080 ?

    – krisFR
    Jun 14 '15 at 23:47











  • tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 1083/java

    – Socrates
    Jun 15 '15 at 0:19











  • have you tried accessing wildfly using the URL http://localhost/wildfly/? Mind the trailing slash!

    – Alexander Janssen
    Jun 15 '15 at 6:32











  • I have edited the above question. Plz take a look.

    – Socrates
    Jun 21 '15 at 18:24
















1















I have both Apache and Wildfly installed on a Ubuntu 14.04 system. Now I'd like to make Wildfly (locally http://localhost:8080) accessible from Apache (http://webserver/wildfly). How would I have to do that?



Sofar, I've enabled the two mods: proxy and proxy_http.
And I've added at the end of the document /etc/apache2/apache2.conf:



ProxyRequests off
ProxyPass /wildfly/ http://localhost:8080/
ProxyPassReverse /wildfly/ http://localhost:8080/


EDIT:



Now half of it works, but the paths are not transformed right. The path to one of my apps running on Wildfly is:



http://webserver/wildfly/testproj/Index.xhtml



But all links on its page are processed like this:



http://webserver/testproj/Page1.xhtml
http://webserver/testproj/Page2.xhtml
http://webserver/testproj/Page3.xhtml


rather than this:



http://webserver/wildfly/testproj/Page1.xhtml
http://webserver/wildfly/testproj/Page2.xhtml
http://webserver/wildfly/testproj/Page3.xhtml


If I run Wildfly locally, everything works fine. This lets me believe that there must be an error in the Apache Reverse Proxy configuration. Is that right? What must I do to have Apache parse the right addresses / links?










share|improve this question
















bumped to the homepage by Community 6 hours ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
















  • What says netstat -anp | grep 8080 ?

    – krisFR
    Jun 14 '15 at 23:47











  • tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 1083/java

    – Socrates
    Jun 15 '15 at 0:19











  • have you tried accessing wildfly using the URL http://localhost/wildfly/? Mind the trailing slash!

    – Alexander Janssen
    Jun 15 '15 at 6:32











  • I have edited the above question. Plz take a look.

    – Socrates
    Jun 21 '15 at 18:24














1












1








1


1






I have both Apache and Wildfly installed on a Ubuntu 14.04 system. Now I'd like to make Wildfly (locally http://localhost:8080) accessible from Apache (http://webserver/wildfly). How would I have to do that?



Sofar, I've enabled the two mods: proxy and proxy_http.
And I've added at the end of the document /etc/apache2/apache2.conf:



ProxyRequests off
ProxyPass /wildfly/ http://localhost:8080/
ProxyPassReverse /wildfly/ http://localhost:8080/


EDIT:



Now half of it works, but the paths are not transformed right. The path to one of my apps running on Wildfly is:



http://webserver/wildfly/testproj/Index.xhtml



But all links on its page are processed like this:



http://webserver/testproj/Page1.xhtml
http://webserver/testproj/Page2.xhtml
http://webserver/testproj/Page3.xhtml


rather than this:



http://webserver/wildfly/testproj/Page1.xhtml
http://webserver/wildfly/testproj/Page2.xhtml
http://webserver/wildfly/testproj/Page3.xhtml


If I run Wildfly locally, everything works fine. This lets me believe that there must be an error in the Apache Reverse Proxy configuration. Is that right? What must I do to have Apache parse the right addresses / links?










share|improve this question
















I have both Apache and Wildfly installed on a Ubuntu 14.04 system. Now I'd like to make Wildfly (locally http://localhost:8080) accessible from Apache (http://webserver/wildfly). How would I have to do that?



Sofar, I've enabled the two mods: proxy and proxy_http.
And I've added at the end of the document /etc/apache2/apache2.conf:



ProxyRequests off
ProxyPass /wildfly/ http://localhost:8080/
ProxyPassReverse /wildfly/ http://localhost:8080/


EDIT:



Now half of it works, but the paths are not transformed right. The path to one of my apps running on Wildfly is:



http://webserver/wildfly/testproj/Index.xhtml



But all links on its page are processed like this:



http://webserver/testproj/Page1.xhtml
http://webserver/testproj/Page2.xhtml
http://webserver/testproj/Page3.xhtml


rather than this:



http://webserver/wildfly/testproj/Page1.xhtml
http://webserver/wildfly/testproj/Page2.xhtml
http://webserver/wildfly/testproj/Page3.xhtml


If I run Wildfly locally, everything works fine. This lets me believe that there must be an error in the Apache Reverse Proxy configuration. Is that right? What must I do to have Apache parse the right addresses / links?







proxy reverse-proxy apache-2.4 ubuntu-14.04 wildfly8






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jun 21 '15 at 18:23







Socrates

















asked Jun 14 '15 at 23:23









SocratesSocrates

161112




161112





bumped to the homepage by Community 6 hours ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.







bumped to the homepage by Community 6 hours ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.















  • What says netstat -anp | grep 8080 ?

    – krisFR
    Jun 14 '15 at 23:47











  • tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 1083/java

    – Socrates
    Jun 15 '15 at 0:19











  • have you tried accessing wildfly using the URL http://localhost/wildfly/? Mind the trailing slash!

    – Alexander Janssen
    Jun 15 '15 at 6:32











  • I have edited the above question. Plz take a look.

    – Socrates
    Jun 21 '15 at 18:24



















  • What says netstat -anp | grep 8080 ?

    – krisFR
    Jun 14 '15 at 23:47











  • tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 1083/java

    – Socrates
    Jun 15 '15 at 0:19











  • have you tried accessing wildfly using the URL http://localhost/wildfly/? Mind the trailing slash!

    – Alexander Janssen
    Jun 15 '15 at 6:32











  • I have edited the above question. Plz take a look.

    – Socrates
    Jun 21 '15 at 18:24

















What says netstat -anp | grep 8080 ?

– krisFR
Jun 14 '15 at 23:47





What says netstat -anp | grep 8080 ?

– krisFR
Jun 14 '15 at 23:47













tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 1083/java

– Socrates
Jun 15 '15 at 0:19





tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 1083/java

– Socrates
Jun 15 '15 at 0:19













have you tried accessing wildfly using the URL http://localhost/wildfly/? Mind the trailing slash!

– Alexander Janssen
Jun 15 '15 at 6:32





have you tried accessing wildfly using the URL http://localhost/wildfly/? Mind the trailing slash!

– Alexander Janssen
Jun 15 '15 at 6:32













I have edited the above question. Plz take a look.

– Socrates
Jun 21 '15 at 18:24





I have edited the above question. Plz take a look.

– Socrates
Jun 21 '15 at 18:24










1 Answer
1






active

oldest

votes


















0














I hope that you solved your problem, but in case that there is someone else who my need an answer for this question here is the solution,



For web applications that are deployed outside an EAR file (WAR deployment)



In the web-inf folder




MyApp/src/main/webapp/WEB-INF/




add a jboss-web.xml file with this content where / is the root deployment if you would like to deploy it as a root for your case just change the "/" whit "testproj".



<jboss-web>
<context-root>/</context-root>
</jboss-web>


EAR file



From the official documentation (please check the reference) you can find that inside the EAR file, the context root is defined in the application.xml file. in the following example the context root of the web-client.war is bank, so the application is set to /bank which mean that the URL will be www.domaine.com/bank



 <module>
<ejb>bank-ejb.jar</ejb>
</module>
<module>
<web>
<web-uri>web-client.war</web-uri>
<context-root>bank</context-root>
</web>
</module>




reference :
Jboss Doc - Chapter 6. Setting the context root of a web application






share|improve this answer

























    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "2"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f698987%2fapache-reverse-proxy-with-wildfly%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    I hope that you solved your problem, but in case that there is someone else who my need an answer for this question here is the solution,



    For web applications that are deployed outside an EAR file (WAR deployment)



    In the web-inf folder




    MyApp/src/main/webapp/WEB-INF/




    add a jboss-web.xml file with this content where / is the root deployment if you would like to deploy it as a root for your case just change the "/" whit "testproj".



    <jboss-web>
    <context-root>/</context-root>
    </jboss-web>


    EAR file



    From the official documentation (please check the reference) you can find that inside the EAR file, the context root is defined in the application.xml file. in the following example the context root of the web-client.war is bank, so the application is set to /bank which mean that the URL will be www.domaine.com/bank



     <module>
    <ejb>bank-ejb.jar</ejb>
    </module>
    <module>
    <web>
    <web-uri>web-client.war</web-uri>
    <context-root>bank</context-root>
    </web>
    </module>




    reference :
    Jboss Doc - Chapter 6. Setting the context root of a web application






    share|improve this answer






























      0














      I hope that you solved your problem, but in case that there is someone else who my need an answer for this question here is the solution,



      For web applications that are deployed outside an EAR file (WAR deployment)



      In the web-inf folder




      MyApp/src/main/webapp/WEB-INF/




      add a jboss-web.xml file with this content where / is the root deployment if you would like to deploy it as a root for your case just change the "/" whit "testproj".



      <jboss-web>
      <context-root>/</context-root>
      </jboss-web>


      EAR file



      From the official documentation (please check the reference) you can find that inside the EAR file, the context root is defined in the application.xml file. in the following example the context root of the web-client.war is bank, so the application is set to /bank which mean that the URL will be www.domaine.com/bank



       <module>
      <ejb>bank-ejb.jar</ejb>
      </module>
      <module>
      <web>
      <web-uri>web-client.war</web-uri>
      <context-root>bank</context-root>
      </web>
      </module>




      reference :
      Jboss Doc - Chapter 6. Setting the context root of a web application






      share|improve this answer




























        0












        0








        0







        I hope that you solved your problem, but in case that there is someone else who my need an answer for this question here is the solution,



        For web applications that are deployed outside an EAR file (WAR deployment)



        In the web-inf folder




        MyApp/src/main/webapp/WEB-INF/




        add a jboss-web.xml file with this content where / is the root deployment if you would like to deploy it as a root for your case just change the "/" whit "testproj".



        <jboss-web>
        <context-root>/</context-root>
        </jboss-web>


        EAR file



        From the official documentation (please check the reference) you can find that inside the EAR file, the context root is defined in the application.xml file. in the following example the context root of the web-client.war is bank, so the application is set to /bank which mean that the URL will be www.domaine.com/bank



         <module>
        <ejb>bank-ejb.jar</ejb>
        </module>
        <module>
        <web>
        <web-uri>web-client.war</web-uri>
        <context-root>bank</context-root>
        </web>
        </module>




        reference :
        Jboss Doc - Chapter 6. Setting the context root of a web application






        share|improve this answer















        I hope that you solved your problem, but in case that there is someone else who my need an answer for this question here is the solution,



        For web applications that are deployed outside an EAR file (WAR deployment)



        In the web-inf folder




        MyApp/src/main/webapp/WEB-INF/




        add a jboss-web.xml file with this content where / is the root deployment if you would like to deploy it as a root for your case just change the "/" whit "testproj".



        <jboss-web>
        <context-root>/</context-root>
        </jboss-web>


        EAR file



        From the official documentation (please check the reference) you can find that inside the EAR file, the context root is defined in the application.xml file. in the following example the context root of the web-client.war is bank, so the application is set to /bank which mean that the URL will be www.domaine.com/bank



         <module>
        <ejb>bank-ejb.jar</ejb>
        </module>
        <module>
        <web>
        <web-uri>web-client.war</web-uri>
        <context-root>bank</context-root>
        </web>
        </module>




        reference :
        Jboss Doc - Chapter 6. Setting the context root of a web application







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Feb 1 at 23:05

























        answered Feb 1 at 22:53









        BartttttBarttttt

        185




        185






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Server Fault!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f698987%2fapache-reverse-proxy-with-wildfly%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            117736 Шеррод Примітки | Див. також | Посилання | Навігаційне...

            As a Security Precaution, the user account has been locked The Next CEO of Stack OverflowMS...

            Маріан Котлеба Зміст Життєпис | Політичні погляди |...