drupal 8 + nginx + centos 7

Events happening in the community are now at Drupal community events on www.drupal.org.
mnovoa's picture

Hello

Install drupal 8 on nginx in a centos 7 server. I did not have problems in the installation, but only the front page works.

Any page of the type:

user / login
content / add
admin / themes
etc.

it shows me a "not found", I suppose it is an error in the rule of the rewite of the nginx.

Does anyone have an example of how to configure ?, or if I have to review something else.

thanks for the help from now

Comments

When I had to do that I

rodrigoaguilera's picture

When I had to do that I always followed the official recipe

https://www.nginx.com/resources/wiki/start/topics/recipes/drupal/

Hola Manuel

translector's picture

Sometime ago I had a similar issue.

For some weird reason I still don't know, I didn't have a .htaccess file in my root directory.

After uploading this file, all the pages started to show up.

I hope this can help you.

Cheers and have a nice day.

Jorge

thanks all, but ....

mnovoa's picture

Thank you all for the answers

Follow the recommended settings at: https: //www.nginx.com/resources/wiki/start/topics/recipes/drupal/

but it still does not work

any other idea?

check htaccess

psychcentral's picture

Are you sure that your .htaccess file has proper permissions set and is writeable by the server's user? It sounds like that's where the problem is...

nginx does not read and does

rodrigoaguilera's picture

nginx does not read and does not understand .htaccess files.

Sadly Drupal does no ship with configuration for nginx.

(wrong)Cookie domain set in

heyyo's picture

(wrong)Cookie domain set in your settings.php ?

(wrong)Cookie domain set in

heyyo's picture

(wrong)Cookie domain set in your settings.php ?

(wrong)Cookie domain set in

mnovoa's picture

how change that?

in settings.php, only find one line with "cookie"

$settings['omit_vary_cookie'] = TRUE;

any help?

(wrong)Cookie domain set in

mnovoa's picture

how change that?

in settings.php, only find one line with "cookie"

$settings['omit_vary_cookie'] = TRUE;

any help?

Re: drupal 8 + nginx + centos 7

chenzero's picture

Hi mnovoa ,
I encountered the same problem on Ubuntu 16.04. 404 error with the lastest 8.5.0 installation.
After I changed my nginx.conf as following,
the lastest drupal works.

location / {
try_files $uri /drupal-8.5.0/index.php?$request_uri;
}

I installed Drupal in drupal-8.5.0/ dir, change that to your installation folder.
or you can try the lastest drupal 7.57 version, no need to change nginx.conf.

HTH,
chenzero

Thank you for sharing. got it

dongtian's picture

Thank you for sharing. got it to work

Chile

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: