Commit e19bf0bd authored by Xavier Guimard's avatar Xavier Guimard

Test config file for Nginx (#LEMONDAP-583)

git-svn-id: svn://svn.forge.objectweb.org/svnroot/lemonldap/trunk@4394 1dbb9719-a921-0410-b57f-c3a383c2c641
parent 394edcf2
......@@ -308,8 +308,12 @@ prepare_test_server:
MANAGERPSGIDIR=`pwd`/e2e-tests \
DEFDOCDIR=`pwd`/doc \
FRDOCDIR=`pwd`/po-doc/fr
@cp e2e-tests/lmConf-1.js e2e-tests/lemonldap-ng.ini e2e-tests/env.conf e2e-tests/conf/
@perl -i -pe 'BEGIN{$$p=`pwd`;chomp $$p}s#__pwd__#$$p#;s/__port__/$(TESTWEBSERVERPORT)/' e2e-tests/conf/lemonldap-ng.ini e2e-tests/conf/lmConf-1.js e2e-tests/conf/env.conf
@cp e2e-tests/lmConf-1.js e2e-tests/lemonldap-ng.ini e2e-tests/env.conf e2e-tests/test-nginx.conf e2e-tests/conf/
@perl -i -pe 'BEGIN{$$p=`pwd`;chomp $$p}s#__pwd__#$$p#;s/__port__/$(TESTWEBSERVERPORT)/' \
e2e-tests/conf/lemonldap-ng.ini \
e2e-tests/conf/lmConf-1.js \
e2e-tests/conf/env.conf \
e2e-tests/conf/test-nginx.conf
e2e-tests/conf/apache2.pid: start_web_server
......
server {
listen __port__;
server_name test1.example.com;
root __pwd__/e2e-tests/conf/site;
# Internal authentication request
location = /lmauth {
internal;
include /etc/nginx/fastcgi_params;
fastcgi_pass unix:__pwd__/e2e-tests/conf/llng.sock;
# Drop post datas
fastcgi_pass_request_body off;
fastcgi_param CONTENT_LENGTH "";
# Keep original hostname
fastcgi_param HOST $http_host;
# Keep original request (LLNG server will received /llauth)
fastcgi_param X_ORIGINAL_URI $request_uri;
}
# Client requests
location / {
auth_request /lmauth;
auth_request_set $lmremote_user $upstream_http_lm_remote_user;
auth_request_set $lmlocation $upstream_http_location;
error_page 401 $lmlocation;
include /etc/nginx/fastcgi_params;
fastcgi_pass unix:__pwd__/e2e-tests/conf/llng.sock;
auth_request_set $headername1 $upstream_http_headername1;
auth_request_set $headervalue1 $upstream_http_headervalue1;
fastcgi_param $fheadername1 $headervalue1;
auth_request_set $headername2 $upstream_http_headername2;
auth_request_set $headervalue2 $upstream_http_headervalue2;
fastcgi_param $fheadername2 $headervalue2;
auth_request_set $headername3 $upstream_http_headername3;
auth_request_set $headervalue3 $upstream_http_headervalue3;
fastcgi_param $fheadername3 $headervalue3;
auth_request_set $headername4 $upstream_http_headername4;
auth_request_set $headervalue4 $upstream_http_headervalue4;
fastcgi_param $fheadername4 $headervalue4;
}
location = /lmstatus {
include /etc/nginx/fastcgi_params;
fastcgi_pass unix:__pwd__/e2e-tests/conf/llng.sock;
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment