Listen 7777
Listen 8888
Listen 21


Header set Access-Control-Allow-Origin: "http://servername.dominio.com.br"
Header set Access-Control-Allow-Headers: "Content-Type, X-Requested-With, accept-version"
Header set Access-Control-Allow-Methods: "GET, PUT, OPTIONS, DELETE, POST"
Header Set Access-Control-Request-Method: "GET, PUT, OPTIONS, DELETE, POST"
ProxyRequests Off
ProxyVia On
AllowConnect 7777
AllowConnect 8888
AllowConnect 21

<VirtualHost *:80>
    ServerName servername.dominio.com.br
    ProxyPreserveHost On
    ProxyPass / http://192.168.0.110:8080/ 
    Keepalive=On
    ProxyPassReverse / http://servername.dominio.com.br/
</VirtualHost>

<VirtualHost *:7777>
    ServerName servername.dominio.com.br
    SetEnv proxy-sendchuncked
    <Proxy *>
        Order deny,allow
        Allow from all
    </Proxy>
    ProxyPreserveHost On
    RewriteEngine On
    RewriteCond %{REQUEST_URI} ^/socket.io
    RewriteCond %{QUERY_STRING} transport=websocket
    RewriteRule /(.*) ws://192.168.0.110:7777/$1
    ProxyPass /socket.io http://192.168.0.110:7777/socket.io keepalive=On retry=1 acquire=3000 timeout=5
    ProxyPassReverse /socket.io http://192.168.0.110:7777/socket.io retry=0
</VirtualHost>


<VirtualHost *:8080>
    ServerName servername.dominio.com.br
    SetEnv proxy-sendchuncked
    ProxyPreserveHost On
    ProxyPass / http://192.168.0.110:8080/  Keepalive=On
    ProxyPassReverse / http://192.168.0.110:8080/
</VirtualHost>

<VirtualHost *:8888>
    ServerName servername.dominio.com.br
    SetEnv proxy-sendchuncked
    ProxyPreserveHost On
    ProxyPass / http://192.168.0.110:8888/Keepalive=On
    ProxyPassReverse / http://192.168.0.110:8888/
</VirtualHost>