Game Development Reference
In-Depth Information
--pid-path=/var/run/nginx.pid \
--error-log-path=/var/log/nginx/error.log \
--http-log-path=/var/log/nginx/access.log \
--with-http_ssl_module \
--without-http_proxy_module \
--add-module=/usr/src/nginx-rtmp-module
Then, create the directory that will hold your HTML files, and we can
make
and then
install
. This takes about 15 minutes.
# sudo mkdir -p /var/www
# sudo make
# sudo make install
# nginx -v
The last line should display the version number we just compiled and that would
mean that our custom nginx is now installed. You can start nginx using
service
nginx start
and browse to your Pi to see the default webpage. If it's all ok,
then we can stop it using
service nginx stop
.
Configuring nginx
This file configures
nginx-rtmp
to accept FLV-wrapped video in h264 format and
then allows clients to stream it on a web page using an open source flash stream
player. You should edit the file located at
/etc/nginx/nginx.conf
.
http {
server {
listen 80;
}
}
rtmp {
server {
listen 1935;
#publish_time_fix off; #gstreamer only
application src{
live on;
}
}
}