# Seperating ipv6 and ipv4 traffic

**URL:** <https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971>\
**Category:** NGINX\
**Created:** [May 14, 2011, 5:48pm UTC](https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971 "2011-05-14T17:48:56Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![dubstep](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/cdc98d/32.png) [@dubstep](https://www.ruby-forum.com/u/dubstep)\
**Post date:** [May 14, 2011, 5:48pm UTC](https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971/1 "2011-05-14T17:48:56Z")

</div>

server {  
server\_name [secure.mydomain.com](http://secure.mydomain.com);  
listen 443;  
gzip on;  
gzip\_comp\_level 1;  
gzip\_types text/plain text/html text/css  
application/x-javascript text/xml text/javascript;  
gzip\_static on;  
gzip\_http\_version 1.1;  
gzip\_proxied any;  
gzip\_disable “msie6”;  
gzip\_vary on;  
ssl on;  
ssl\_ciphers RC4:ALL:-LOW:-EXPORT:!ADH:!MD5;  
keepalive\_timeout 0;  
ssl\_certificate /root/server.pem;  
ssl\_certificate\_key /root/ssl.key;

```
       location / {
            root /var/www;
            index index.html index.htm index.php;
        }

    }

```

Seems to work well (and accepts both SSL ipv4/ipv6 since they point to  
same ip)…  
But I’d like to move ipv4-only traffic away to another ip. How is this  
done? I’m guessing I create 2 of these, specifying ipv4 in one and  
ipv6 in the other?

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [May 14, 2011, 5:58pm UTC](https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971/2 "2011-05-14T17:58:12Z")

</div>

Ah, also, with using redirect with a request SSL then redirected to a  
non-ssl site work?

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [May 14, 2011, 6:24pm UTC](https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971/3 "2011-05-14T18:24:07Z")

</div>

listen on the IPv6 addr.

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [May 15, 2011, 2:34pm UTC](https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971/4 "2011-05-15T14:34:51Z")

</div>

On Sun, May 15, 2011 at 03:58:01AM +1200, Ryan B wrote:

> Ah, also, with using redirect with a request SSL then redirected to a  
> non-ssl site work?

Sorry, I do not understand the question.

–  
Igor S.

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [May 15, 2011, 2:33pm UTC](https://www.ruby-forum.com/t/seperating-ipv6-and-ipv4-traffic/206971/5 "2011-05-15T14:33:36Z")

</div>

On Sun, May 15, 2011 at 03:48:19AM +1200, Ryan B wrote:

> ```
> gzip_disable "msie6";
> }
> 
> }
> 
> ```
> 
> Seems to work well (and accepts both SSL ipv4/ipv6 since they point to  
> same ip)..  
> But I’d like to move ipv4-only traffic away to another ip. How is this  
> done? I’m guessing I create 2 of these, specifying ipv4 in one and  
> ipv6 in the other?

server {  
listen 192.168.1.1:443;  
listen […]:443;

–  
Igor S.
