Welcome! Log In Create A New Profile

Advanced

Re: FreeBSD & nginx

November 23, 2010 07:39AM
Я человек сильно не просвещенный в вашем сленге и особо ничего не понял.
Но, судя по всему их и не должно быть на freebsd? Я просто че переживаю, так как на debian они у меня были...
Тогда вопрос другой, это все вставить в nginx.conf ?

[code]
### drupal-cgm file follows:
# --- cut here ---
# nginx - /etc/nginx/sites-available/drupal-cgm
#
server {
listen 80 default;
server_name _; # non defined server
return 444; # silently drop request
}
server {
listen clinica.0:80;
server_name www.clinica.0;
rewrite ^(.*) http://clinica.0$1 permanent;
}
server {
listen clinica.0:80;
server_name clinica.0;

access_log /var/log/nginx/drupal-cgm.access.log;
error_log /var/log/nginx/drupal-cgm.error.log;

root /var/www/drupal-cgm;

# restrict request methods to: GET|HEAD|POST
if ( $request_method !~ ^(GET|HEAD|POST)$ ) {
return 444;
break;
}

# hide drupal system files
location ~*
((cron\.php|settings\.php)|\.(htaccess|engine|inc|info|install|module|profile|pl|po|sh|.*sql|theme|tpl(\.php)?|xtmpl)$|^(Entries.*|Repository|Root|Tag|Template))$
{
deny all;
}

# # rewrite domain name without the leading www.
# if ($host ~* ^www\.(.*)) {
# set $host_without_www $1;
# # bellow $1 contains '/foo', not 'www.mydomain.com/foo'
# rewrite ^(.*)$ http://$host_without_www$1 permanent;
# }

location / {
index index.php index.html;
try_files $uri $uri/ @drupal;
}

location @drupal {
# clean url rewrite for Drupal
rewrite ^/(.*)$ /index.php?q=$1 last;
#rewrite ^/(\w*)/(.*)$ /$1/index.php?q=$2 last;
}

location ~ \.php$ {
include /etc/nginx/fastcgi_params;
fastcgi_pass unix:/tmp/php-fastcgi.socket;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
# --- cut here ---
[/code]
Subject Author Posted

FreeBSD & nginx

KaMaToZzz November 23, 2010 07:20AM

Re: FreeBSD & nginx

Alexander Petrovsky November 23, 2010 07:28AM

Re: FreeBSD & nginx

Sergey Shepelev November 23, 2010 07:30AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 07:39AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 07:58AM

Re: FreeBSD & nginx

Дмитрий Андреев November 23, 2010 07:46AM

Re: FreeBSD & nginx

Sergey Shepelev November 23, 2010 07:46AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 08:31AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 08:48AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 08:58AM

Re: FreeBSD & nginx

Anton Yuzhaninov November 23, 2010 08:38AM

Re: FreeBSD & nginx

Sergey Shepelev November 23, 2010 08:38AM

Re: FreeBSD & nginx

DeD MustDIE November 23, 2010 09:08AM

Re: FreeBSD & nginx

Anton Gorlov November 23, 2010 09:32AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 09:48AM

Re: FreeBSD & nginx

Sergey Averyanov November 23, 2010 09:54AM

Re: FreeBSD & nginx

Sergey Shepelev November 23, 2010 10:08AM

Re: FreeBSD & nginx

KaMaToZzz November 23, 2010 10:27AM

Re: FreeBSD & nginx

Валентин Бартенев November 23, 2010 11:08AM

Re: FreeBSD & nginx

KaMaToZzz November 25, 2010 02:21AM

Re: FreeBSD & nginx

xpahos@gmail.com November 25, 2010 04:06AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

mrw
Guests: 85
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready