Skip to content

Nginx in subfolder #19

@zadro

Description

@zadro

Racking my brain on getting this to work. I have have a WP install and other things in /home/site/www and trying to install CI in /home/site/www/api

Keep getting 404 errors. Thoughts?

nginx conf below. Thanks!

        location /api {
                root /home/site/www/api/public;
                index index.php;
                try_files $uri $uri/ /index.php?$args;

                location ~ \.php$ {
                        try_files $uri =404;
                        include fastcgi_params;
                        fastcgi_param SCRIPT_FILENAME $request_filename;
                        fastcgi_split_path_info ^(.+\.php)(/.+)$;
                        fastcgi_pass unix:/var/run/php_fpm.sock;
                }
        }

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions