SSOwat/README.md

58 lines
784 B
Markdown
Raw Normal View History

2013-10-15 10:11:39 +02:00
SSOwat
======
2013-10-16 11:59:48 +02:00
A simple LDAP SSO for nginx, written in Lua
2013-10-15 10:11:39 +02:00
2013-10-15 10:16:42 +02:00
Requirements
------------
2013-10-16 11:59:48 +02:00
- Nginx-extras from Debian wheezy-backports
- lua-json
- lua-ldap
2013-10-16 12:00:08 +02:00
2013-10-16 11:59:48 +02:00
OR
2013-10-16 12:00:08 +02:00
2013-10-16 11:59:48 +02:00
- Nginx "Openresty" flavored : http://openresty.org/
- lua-ldap
2013-10-15 10:16:42 +02:00
2013-10-15 10:11:39 +02:00
Example Nginx conf
------------------
2013-10-15 10:13:34 +02:00
```nginx
2013-10-15 10:11:39 +02:00
lua_package_path "/usr/share/lua/5.1/nginx/?.lua;;"; # For Debian
2013-10-16 11:31:51 +02:00
2013-10-15 10:11:39 +02:00
init_by_lua_file path/to/init.lua;
access_by_lua_file path/to/access.lua;
# SSO domain
server {
listen 80;
server_name mydomain.com;
2013-10-16 11:31:51 +02:00
root /var/www/mydomain.com;
2013-10-15 10:11:39 +02:00
2013-10-16 11:31:51 +02:00
location /ssowat {
alias /var/www/ssowat;
default_type text/html;
2013-10-15 10:11:39 +02:00
}
2013-10-16 11:31:51 +02:00
location /whatever {
2013-10-15 10:11:39 +02:00
...
2013-10-16 11:31:51 +02:00
}
2013-10-15 10:11:39 +02:00
}
# Other domain
server {
listen 80;
server_name myotherdomain.com;
2013-10-16 11:31:51 +02:00
root /var/www/myotherdomain.com;
2013-10-15 10:11:39 +02:00
...
}
2013-10-15 10:13:34 +02:00
```