I have indeed several virtual servers. I have a specific one which serves different content whether a client connects in HTTP or HTTPS (basically the HTTP content provides directions for the HTTPS setup). I also have one virtual server which I want listening on IPv4 only, not IPv6.
That's why I prefer managing the listen directives in virtual servers rather than in the 'http' directive block. Is there no other mean than using global 'listen' directives? --- *B. R.* On Fri, Apr 5, 2013 at 6:21 PM, Maxim Dounin <[email protected]> wrote: > Hello! > > On Fri, Apr 05, 2013 at 06:07:23PM -0400, B.R. wrote: > > > Hello, > > > > @Maxim > > I tried the duplicate configuration entries: > > listen 80; > > listen [::]:80 ipv6only=on; > > > > I has the following error: > > nginx: [emerg] duplicate listen options for [::]:80 in > > /etc/nginx/conf.d/***.conf:3 > > If you have multiple virtual server{}s with the same listening > sockets used, you have to specify listening options in a single listen > directive only. > > That is, add "ipv6only=on" to a listen directive in first/default > server in your configuration. This will do the trick. > > -- > Maxim Dounin > http://nginx.org/en/donation.html > > _______________________________________________ > nginx mailing list > [email protected] > http://mailman.nginx.org/mailman/listinfo/nginx >
_______________________________________________ nginx mailing list [email protected] http://mailman.nginx.org/mailman/listinfo/nginx
