|
| 1 | +<!DOCTYPE html> |
| 2 | +<html> |
| 3 | + <head> |
| 4 | + <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| 5 | + <title>Crothen</title> |
| 6 | + <link type="text/css" rel="stylesheet" href="https://crothen97.github.io/assets/css/bootstrap.css"/> |
| 7 | + <link type="text/css" rel="stylesheet" href="https://crothen97.github.io/assets/css/prettify.css"/> |
| 8 | + <style> |
| 9 | + body { |
| 10 | + padding-top: 60px; /* 60px to make the container go all the way to the bottom of the topbar */ |
| 11 | + } |
| 12 | + </style> |
| 13 | + <link type="text/css" rel="stylesheet" href="https://crothen97.github.io/assets/css/bootstrap-responsive.css"/> |
| 14 | + |
| 15 | + </head> |
| 16 | +<body> |
| 17 | + |
| 18 | + <div class="navbar navbar-inverse navbar-fixed-top"> |
| 19 | + <div class="navbar-inner"> |
| 20 | + <div class="container"> |
| 21 | + <button type="button" class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse"> |
| 22 | + <span class="icon-bar"></span> |
| 23 | + <span class="icon-bar"></span> |
| 24 | + <span class="icon-bar"></span> |
| 25 | + </button> |
| 26 | + <a class="brand" href="https://crothen97.github.io">Crothen</a> |
| 27 | + <div class="nav-collapse collapse"> |
| 28 | + <ul class="nav"> |
| 29 | + <li><a href="https://crothen97.github.io/cv">cv</a></li> |
| 30 | + <li><a href="https://crothen97.github.io/cpp">cpp</a></li> |
| 31 | + <li><a href="https://crothen97.github.io/python">python</a></li> |
| 32 | + <li><a href="https://crothen97.github.io/matlab">matlab</a></li> |
| 33 | + <li><a href="https://crothen97.github.io/java">java</a></li> |
| 34 | + <li><a href="https://crothen97.github.io/linux">linux</a></li> |
| 35 | + <li><a href="https://crothen97.github.io/windows">windows</a></li> |
| 36 | + </ul> |
| 37 | + </div><!--/.nav-collapse --> |
| 38 | + </div> |
| 39 | + </div> |
| 40 | + </div> |
| 41 | + |
| 42 | + <div class="container"> |
| 43 | + <a name="nginx_rtmp_server_on_ubuntu_12_04"></a><h1>Nginx Rtmp Server on Ubuntu 12.04<a class="anchorlink" href="#nginx_rtmp_server_on_ubuntu_12_04"></a></h1> |
| 44 | +<a name="install_nginx_rtmp_server"></a><h2>install nginx rtmp server<a class="anchorlink" href="#install_nginx_rtmp_server"></a></h2> |
| 45 | +<pre class="prettyprint">sudo apt-get install zlib1g-dev |
| 46 | +sudo apt-get install libpcre3 libpcre3-dev |
| 47 | +sudo apt-get install openssl libssl-dev |
| 48 | + |
| 49 | +./configure --prefix=/opt/nginx --sbin-path=/opt/nginx/nginx --conf-path=/home/smbCrothen/rtmp/nginx.conf --pid-path=/opt/nginx/nginx.pid --error-log-path=/home/smbCrothen/rtmp/logs/error.log --with-http_dav_module --with-http_flv_module --with-http_stub_status_module --without-http_scgi_module --without-http_uwsgi_module --without-http_gzip_module --without-http_ssi_module --without-http_proxy_module --without-http_memcached_module --without-http_empty_gif_module --without-mail_pop3_module --without-mail_imap_module --without-mail_smtp_module --with-http_ssl_module --add-module=../nginx-rtmp-module |
| 50 | +make clean |
| 51 | +make && make install</pre> |
| 52 | +<a name="config_of_nginx_rtmp"></a><h2>config of nginx_rtmp<a class="anchorlink" href="#config_of_nginx_rtmp"></a></h2> |
| 53 | +<pre class="prettyprint">#user nobody; |
| 54 | +worker_processes 1; |
| 55 | +events { |
| 56 | + worker_connections 1024; |
| 57 | +} |
| 58 | + |
| 59 | +http { |
| 60 | + include mime.types; |
| 61 | + default_type application/octet-stream; |
| 62 | + |
| 63 | + sendfile on; |
| 64 | + #tcp_nopush on; |
| 65 | + |
| 66 | + keepalive_timeout 65; |
| 67 | + |
| 68 | + server { |
| 69 | + listen 80; |
| 70 | + server_name localhost; |
| 71 | + |
| 72 | + location / { |
| 73 | + root /home/smbCrothen/html; |
| 74 | + index index.html; |
| 75 | + } |
| 76 | + |
| 77 | + #error_page 404 /404.html; |
| 78 | + |
| 79 | + error_page 500 502 503 504 /50x.html; |
| 80 | + location = /50x.html { |
| 81 | + root html; |
| 82 | + } |
| 83 | + |
| 84 | + location /stat { |
| 85 | + rtmp_stat all; |
| 86 | + rtmp_stat_stylesheet stat.xsl; |
| 87 | + } |
| 88 | + |
| 89 | + location /stat.xsl { |
| 90 | + root /home/smbCrothen/html; |
| 91 | + } |
| 92 | + } |
| 93 | +}</pre> |
| 94 | + |
| 95 | + </div> |
| 96 | + |
| 97 | + <script type="text/javascript" src="https://crothen97.github.io/assets/js/jquery.min.js"></script> |
| 98 | + <script type="text/javascript" src="https://crothen97.github.io/assets/js/bootstrap.min.js"></script> |
| 99 | + <script type="text/javascript" src="https://crothen97.github.io/assets/js/prettify.js"></script> |
| 100 | + <script type="text/javascript" src="https://crothen97.github.io/assets/js/runner.js"></script> |
| 101 | +</body> |
| 102 | +</html> |
0 commit comments