Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Xavier Bachelot
lemonldap-ng
Commits
6ef8d70f
Commit
6ef8d70f
authored
Feb 08, 2016
by
Yadd
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Manage fastcgi server startup, not finished
parent
a648380a
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
30 additions
and
15 deletions
+30
-15
debian/lemonldap-ng-fastcgi-server.default
debian/lemonldap-ng-fastcgi-server.default
+4
-7
debian/lemonldap-ng-fastcgi-server.init
debian/lemonldap-ng-fastcgi-server.init
+4
-2
debian/lemonldap-ng-fastcgi-server.postinst
debian/lemonldap-ng-fastcgi-server.postinst
+15
-0
debian/lemonldap-ng-fastcgi-server.service
debian/lemonldap-ng-fastcgi-server.service
+2
-1
debian/liblemonldap-ng-manager-perl.links
debian/liblemonldap-ng-manager-perl.links
+1
-1
e2e-tests/handler/01-redirect.js
e2e-tests/handler/01-redirect.js
+3
-3
fastcgi-server/sbin/llng-fastcgi-server
fastcgi-server/sbin/llng-fastcgi-server
+1
-1
No files found.
debian/lemonldap-ng-fastcgi-server.default
View file @
6ef8d70f
# Number of process (default: 7)
#NPROC = 7
# Portal CGI path
#PORTAL_PATH = /var/lib/lemonldap-ng/portal
# Unix socket to listen to
#
SOCKET
= /run
/llng-fastcgi.sock
SOCKET
=/var/run/llng-fastcgi-server
/llng-fastcgi.sock
# Pid file
#
PID
=
/run/llng-fastcgi.pid
PID
=/var
/run/llng-fastcgi.pid
# User and GROUP
USER
=
www-data
GROUP
=
www-data
USER
=
www-data
GROUP
=
www-data
debian/lemonldap-ng-fastcgi-server.init
View file @
6ef8d70f
...
...
@@ -11,7 +11,7 @@
### END INIT INFO
PATH
=
/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON
=
/usr/sbin/ll
g
n-fastcgi-server
DAEMON
=
/usr/sbin/lln
g
-fastcgi-server
NAME
=
llng-fastcgi-server
DESC
=
llng-fastcgi-server
...
...
@@ -29,9 +29,11 @@ test -x $DAEMON || exit 0
# Try to extract llng-fastcgi-server pidfile
if
[
-z
"
$PID
"
]
;
then
PID
=
/run/llng-fastcgi-server.pid
PID
=
/
var/
run/llng-fastcgi-server.pid
fi
DAEMON_OPTS
=
"-p
${
PID
}
-u
${
USER
}
-g
${
GROUP
}
-s
${
SOCKET
}
"
start_server
()
{
# Start the daemon/service
#
...
...
debian/lemonldap-ng-fastcgi-server.postinst
0 → 100644
View file @
6ef8d70f
#!/bin/sh
set
-e
USER
=
"www-data"
GROUP
=
"www-data"
CHOWN
=
"/bin/chown"
ID
=
"/usr/bin/id"
if
!
test
-d
/var/run/llng-fastcgi-server
;
then
rm
-rf
/var/run/llng-fastcgi-server
mkdir
/var/run/llng-fastcgi-server
fi
$CHOWN
$USER
:
$GROUP
/var/run/llng-fastcgi-server
debian/lemonldap-ng-fastcgi-server.service
View file @
6ef8d70f
[Unit]
Description
=
FastCGI server for Lemonldap::NG websso system
After
=
network.target
[Service]
Type
=
forking
PIDFile
=
/run/llng-fasctcgi.pid
ExecStart
=
/usr/sbin/llng-fastcgi-server
ExecStart
=
/usr/sbin/llng-fastcgi-server
-u www-data -g www-data -s /var/run/llng-fastcgi-server/llng-fastcgi.sock -p /var/run/llng-fastcgi.pid
ExecStop
=
-/sbin/start-stop-daemon --quiet --stop --retry QUIT/5 --pidfile /run/llng-fasctcgi.sock
TimeoutStop
=
2
KillMode
=
mixed
...
...
debian/liblemonldap-ng-manager-perl.links
View file @
6ef8d70f
/etc/lemonldap-ng/manager-apache2.conf /etc/apache2/sites-available/manager-apache2.conf
/etc/lemonldap-ng/manager-nginx.conf /etc/nginx/sites-available/manager-nginx.conf
/usr/share/lemonldao-ng/manager/static /var/lib/lemonldap-ng/manager/static
e2e-tests/handler/01-redirect.js
View file @
6ef8d70f
...
...
@@ -9,7 +9,7 @@ describe('Lemonldap::NG', function() {
it
(
'
should redirect to portal
'
,
function
()
{
browser
.
ignoreSynchronization
=
true
;
browser
.
driver
.
get
(
'
http://test1.example.com:
'
+
process
.
env
.
TESTWEBSERVERPORT
+
'
/
'
);
expect
(
browser
.
getCurrentUrl
()).
to
Equal
(
'
http://auth.example.com:
'
+
process
.
env
.
TESTWEBSERVERPORT
+
'
/
?url=aHR0cDovL3Rlc3QxLmV4YW1wbGUuY29tOjE5ODc2Lw==
'
);
expect
(
browser
.
getCurrentUrl
()).
to
Match
(
new
RegExp
(
'
^
http://auth.example.com
(
:
'
+
process
.
env
.
TESTWEBSERVERPORT
+
'
)?/
\
?url=aHR0cDovL3Rlc3QxLmV4YW1wbGUuY29tOjE5ODc2Lw==
'
)
)
;
});
it
(
'
should accept authentication as dwho/dwho
'
,
function
()
{
browser
.
driver
.
findElement
(
by
.
xpath
(
"
//input[@name='user']
"
)).
sendKeys
(
'
dwho
'
);
...
...
@@ -17,7 +17,7 @@ describe('Lemonldap::NG', function() {
browser
.
driver
.
findElement
(
by
.
xpath
(
"
//button[@type='submit']
"
)).
click
();
});
it
(
'
should redirect to test1.example.com
'
,
function
()
{
expect
(
browser
.
getCurrentUrl
()).
to
Contain
(
'
http://test1.example.com:
'
+
process
.
env
.
TESTWEBSERVERPORT
+
'
/
'
);
expect
(
browser
.
getCurrentUrl
()).
to
Match
(
new
RegExp
(
'
^
http://test1.example.com
(
:
'
+
process
.
env
.
TESTWEBSERVERPORT
+
'
)?
'
)
);
});
});
});
\ No newline at end of file
});
fastcgi-server/sbin/llng-fastcgi-server
View file @
6ef8d70f
...
...
@@ -44,7 +44,7 @@ my %builder = (
return
$_apps
{
$script
}
->
(
@
_
)
if
(
$_apps
{
$script
}
);
$_apps
{
$script
}
=
CGI::Emulate::
PSGI
->
handler
(
CGI::
Compile
->
compile
(
$script
)
);
return
$_app
{
$script
}
->
(
@
_
);
return
$_app
s
{
$script
}
->
(
@
_
);
};
},
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment