Web applications starts on port 8080, where can I change it?

前端 未结 5 1130
感情败类
感情败类 2021-01-15 13:02

I have Netbeans IDE version 6.8, and Glassfish version 3. My glassfish listener is set to port 81, but when I try to run the simplest web application via the Netbenas IDE it

5条回答
  •  北荒
    北荒 (楼主)
    2021-01-15 13:51

    A bit late, but this should work...

    I don't have 6.8 anymore, but the following is true for 6.9 and 6.10m1 - in the directory /.netbeans//config, there is a file called .nbattrs - edit it, and look for something like:

    Change the value to whatever you've set in the appropriate Glassfish domain. If, like me, you have more than one version of Glassfish installed, or perhaps multiple domains, just look out for the ....displayName keys and follow your nose - it should be obvious which one you're altering.

    HTH,

    John

    NB: you can, of course, delete the server and add it in again using the wizard to select the right ports - but I think editing .nbattrs is far easier

    NB2: there is another .nbattrs file further down the directory chain that also contains glassfish config (can't remember the exact location - sorry!) and this looks like the right place to change the port - but editing this file appears to have no effect as, for me, it gets overridden with whatever is in config/.nbattrs file whenever I start up Netbeans

提交回复
热议问题