Jetty server refuses 127.0.0.1 connections

Not sure what is going on here, but my local berth server, which I run through the maven plugin, for example:

        <plugin>
            <groupId>org.mortbay.jetty</groupId>
            <artifactId>jetty-maven-plugin</artifactId>
            <version>${org.mortbay.jetty.version}</version>
            <configuration>
                <systemProperties>
                    <systemProperty>
                        <name>webapp.env.name</name>
                        <value>local</value>
                    </systemProperty>
                </systemProperties>
                <stopPort>8080</stopPort>
                <stopKey>foo</stopKey>
            </configuration>
        </plugin>

... refuses all connections from 127.0.0.1 ...

For example, if I run curl 'http: // localhost: 8080 , I get a valid html response pointing to the contents of my webapp directory. But curl 'http://127.0.0.1:8080 returns curl: (52) An empty response from the server . Does anyone know how I can properly configure the pier to accept such connections? This complicates the local configurations of our development team a bit.

Thank!

+3
source share

Source: https://habr.com/ru/post/1779490/


All Articles