Nginx Domain Mapping?

I have setup multisite + multi-domains + domain mapping.. but i get error in nginx .. maybe becose it doesn't know how to resolve the mapping.. can you point me in the right direction to solve this issue?

  • strato1986

    Yes i have it installed :slight_frown: this is my site conf if it does help..

    map $http_host $blogid {
        default       -999;
        include /home/nchavez/domains/ ;
    server {
            listen 80;
            #listen [::]:80 default ipv6only=on;
            server_name *;
            root /home/nchavez/domains/;
            access_log /home/nchavez/domains/;
            error_log /home/nchavez/domains/;
            index index.php index.html index.htm;
            error_page 404 /404.html;
            location / {
                try_files $uri $uri/ /index.php?$args;
            location ~ \.php$ {
                try_files $uri =403;
                fastcgi_pass unix:/var/run/php5-fpm-nchavez.sock;
                include fastcgi_params;
            location ~ /\.ht {
                deny all;
                    #WPMU Files
            location ~ ^/files/(.*)$ {
                    try_files /wp-content/blogs.dir/$blogid/$uri /wp-includes/ms-files.php?file=$1 ;
                    access_log off; log_not_found off;      expires max;
            #WPMU x-sendfile to avoid php readfile()
            location ^~ /blogs.dir {
                    alias /home/nchavez/domains/;
                    access_log off; log_not_found off;      expires max;

    and the map.conf contents are:	1;	2;
  • Alexander

    Hi @strato1986,

    I'm sorry we didn't get back to you on this. Ive just setup a free account extension for you so we can continue to work on this if you like, and at the very least you can get domain mapping updated.

    Taking a look at your config here, you need to specify this server block as the default server. This would ensure any requests to your IP get directed to Wordpress, where the URL can be used to identify which site to load

    You can also take a look at the recommended configurations for nginix here:

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.