Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
meta-elphel393
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
meta-elphel393
Commits
1f2cde21
Commit
1f2cde21
authored
Nov 19, 2013
by
Oleg Dzhimiev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1. cgi and fastcgi for lighttpd + php + python
parent
072dd78d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
47 additions
and
33 deletions
+47
-33
elphel393.bb
recipes-core/images/elphel393.bb
+14
-10
lighttpd.conf
recipes-extended/lighttpd/files/lighttpd.conf
+22
-20
lighttpd_1.4.32.bbappend
recipes-extended/lighttpd/lighttpd_1.4.32.bbappend
+6
-1
httpd_port81.conf
recipes-httpd/apache2/files/httpd_port81.conf
+5
-2
No files found.
recipes-core/images/elphel393.bb
View file @
1f2cde21
...
@@ -4,16 +4,20 @@ IMAGE_INSTALL = "packagegroup-core-boot ${ROOTFS_PKGMANAGE_BOOTSTRAP} ${CORE_IMA
...
@@ -4,16 +4,20 @@ IMAGE_INSTALL = "packagegroup-core-boot ${ROOTFS_PKGMANAGE_BOOTSTRAP} ${CORE_IMA
# remove not needed ipkg informations
# remove not needed ipkg informations
IMAGE_INSTALL_append = " python-core \
IMAGE_INSTALL_append = " python-core \
i2c-tools \
htop \
mtd-utils \
i2c-tools \
ethtool \
mtd-utils \
openssh \
ethtool \
net-tools \
net-tools \
lighttpd \
openssh \
lighttpd-module-fastcgi \
nano \
modphp \
lighttpd \
apache2 \
lighttpd-module-fastcgi \
php-cli"
lighttpd-module-cgi \
modphp \
apache2 \
php-cgi \
php-cli"
IMAGE_LINGUAS = " "
IMAGE_LINGUAS = " "
...
...
recipes-extended/lighttpd/files/lighttpd.conf
View file @
1f2cde21
...
@@ -26,7 +26,7 @@ server.modules = (
...
@@ -26,7 +26,7 @@ server.modules = (
# "mod_simple_vhost",
# "mod_simple_vhost",
# "mod_evhost",
# "mod_evhost",
# "mod_userdir",
# "mod_userdir",
#
"mod_cgi",
"mod_cgi"
,
# "mod_compress",
# "mod_compress",
# "mod_ssi",
# "mod_ssi",
# "mod_usertrack",
# "mod_usertrack",
...
@@ -38,7 +38,7 @@ server.modules = (
...
@@ -38,7 +38,7 @@ server.modules = (
## a static document-root, for virtual-hosting take look at the
## a static document-root, for virtual-hosting take look at the
## server.virtual-* options
## server.virtual-* options
server
.
document
-
root
=
"/www/pages
/
"
server
.
document
-
root
=
"/www/pages"
## where to send error-messages to
## where to send error-messages to
server
.
errorlog
=
"/www/logs/lighttpd.error.log"
server
.
errorlog
=
"/www/logs/lighttpd.error.log"
...
@@ -135,12 +135,12 @@ $HTTP["url"] =~ "\.pdf$" {
...
@@ -135,12 +135,12 @@ $HTTP["url"] =~ "\.pdf$" {
# which extensions should not be handle via static-file transfer
# which extensions should not be handle via static-file transfer
#
#
# .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
# .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
static
-
file
.
exclude
-
extensions
= (
".php"
,
".pl"
,
".fcgi"
)
static
-
file
.
exclude
-
extensions
= (
".php"
,
".pl"
,
".fcgi"
,
".py"
)
######### Options that are good to be but not neccesary to be changed #######
######### Options that are good to be but not neccesary to be changed #######
## bind to port (default: 80)
## bind to port (default: 80)
#server.port = 81
server
.
port
=
80
## bind to localhost (default: all interfaces)
## bind to localhost (default: all interfaces)
#server.bind = "grisu.home.kneschke.de"
#server.bind = "grisu.home.kneschke.de"
...
@@ -211,27 +211,29 @@ static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
...
@@ -211,27 +211,29 @@ static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
#### fastcgi module
#### fastcgi module
## read fastcgi.txt for more info
## read fastcgi.txt for more info
## for PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini
## for PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini
fastcgi
.
server
= (
".php"
=>
fastcgi
.
server
= (
".php"
=>
(
"localhost"
=>
(
"localhost"
=>
(
"socket"
=>
"/tmp/php-fastcgi.socket"
,
"bin-path"
=>
"/usr/local/bin/php"
"max-procs"
=>
4
,
)
),
".py"
=>
(
"python-fcgi"
=>
(
(
"socket"
=>
socket_dir
+
"fastcgi.python.socket"
,
"socket"
=>
"/tmp/php-fastcgi.socket"
,
"bin-path"
=>
"test.py"
,
"bin-path"
=>
"/usr/bin/php-cgi"
,
"check-local"
=>
"disable"
,
"max-procs"
=>
4
"max-procs"
=>
4
,
)
)
)
)
)
# ),
# "/test" =>
# (
# "python-fcgi" =>
# (
# "socket" => "/tmp/fastcgi.python.socket",
# "bin-path" => "/usr/bin/python",
# "check-local" => "disable",
# "max-procs" => 4
# )
# )
)
#### CGI module
#### CGI module
cgi
.
assign
= (
".py"
=>
"/usr/bin/python"
)
#cgi.assign = ( ".pl" => "/usr/bin/perl",
#cgi.assign = ( ".pl" => "/usr/bin/perl",
# ".cgi" => "/usr/bin/perl" )
# ".cgi" => "/usr/bin/perl" )
#
#
...
...
recipes-extended/lighttpd/lighttpd_1.4.32.bbappend
View file @
1f2cde21
FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
SRC_URI_append = "file://lighttpd.conf"
SRC_URI_append = "file://lighttpd.conf \
file://test.py"
CONFFILES_${PN} = "${D}/lighttpd.conf"
CONFFILES_${PN} = "${D}/lighttpd.conf"
do_install_append() {
cp ${WORKDIR}/test.py ${D}/www/pages/test.py
}
recipes-httpd/apache2/files/httpd_port81.conf
View file @
1f2cde21
...
@@ -212,8 +212,8 @@ ServerName localhost:81
...
@@ -212,8 +212,8 @@ ServerName localhost:81
# documents. By default, all requests are taken from this directory, but
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
# symbolic links and aliases may be used to point to other locations.
#
#
DocumentRoot
"/
usr/share/apache2/htdocs
"
DocumentRoot
"/
www/pages/
"
<
Directory
"/
usr/share/apache2/htdoc
s"
>
<
Directory
"/
www/page
s"
>
#
#
# Possible values for the Options directive are "None", "All",
# Possible values for the Options directive are "None", "All",
# or any combination of:
# or any combination of:
...
@@ -505,5 +505,8 @@ SSLRandomSeed connect builtin
...
@@ -505,5 +505,8 @@ SSLRandomSeed connect builtin
IncludeOptional
/
etc
/
apache2
/
conf
.
d
/*.
conf
IncludeOptional
/
etc
/
apache2
/
conf
.
d
/*.
conf
IncludeOptional
/
etc
/
apache2
/
modules
.
d
/*.
conf
IncludeOptional
/
etc
/
apache2
/
modules
.
d
/*.
conf
<
FilesMatch
\.
php
$>
SetHandler
application
/
x
-
httpd
-
php
</
FilesMatch
>
PidFile
/
run
/
httpd
.
pid
PidFile
/
run
/
httpd
.
pid
\ No newline at end of file
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