{"id":1045,"date":"2014-08-27T17:45:42","date_gmt":"2014-08-27T09:45:42","guid":{"rendered":"https:\/\/cowman-chiang.no-ip.org\/wordpress\/?p=1045"},"modified":"2023-10-31T15:46:01","modified_gmt":"2023-10-31T07:46:01","slug":"ubuntu-x64-%e5%bf%ab%e9%80%9f%e5%ae%89%e8%a3%9d-nginx-with-rtmp-module","status":"publish","type":"post","link":"https:\/\/cowmanchiang.me\/wp\/?p=1045","title":{"rendered":"Ubuntu x64 \u5feb\u901f\u5b89\u88dd Nginx with RTMP module"},"content":{"rendered":"<pre lang=\"bash\">\n#!\/bin\/sh\napt-get install build-essential libpcre3 libpcre3-dev libssl-dev libxslt-dev -y\ncd \/tmp\nwget http:\/\/nginx.org\/download\/nginx-1.7.3.tar.gz\nwget https:\/\/github.com\/arut\/nginx-rtmp-module\/archive\/master.zip\ntar -zxvf nginx-1.7.3.tar.gz \napt-get install unzip -y\nunzip master.zip \ncd nginx-1.7.3\/\n.\/configure --with-http_ssl_module --with-http_xslt_module --add-module=..\/nginx-rtmp-module-master\nmake\nmake install\n\ncp \/tmp\/nginx-rtmp-module-master\/stat.xsl \/usr\/local\/nginx\/html\/\ncp \/usr\/local\/nginx\/conf\/nginx.conf \/usr\/local\/nginx\/conf\/nginx.conf.bak\n\necho \" \" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"rtmp {\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"        server {\"  >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                listen 1935;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                chunk_size 4096;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \" \" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                application live {\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                        live on;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                        record off;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                        #allow publish 127.0.0.1;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                        #deny publish all;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                        #allow play 127.0.0.1;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                        #deny play all;\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"                }\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"        }\" >> \/usr\/local\/nginx\/conf\/nginx.conf\necho \"}\" >> \/usr\/local\/nginx\/conf\/nginx.conf\n\n# \u9019\u908a\u8acb\u8907\u88fd http:\/\/wiki.nginx.org\/Nginx-init-ubuntu \u5167\u5bb9\u81f3 nginx \u6a94\u6848\u4e2d\ncd \/etc\/init.d\/\nvim nginx\nchmod +x nginx\n\nservice nginx start\n# service nginx start|stop|reload\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>#!\/bin\/sh apt-get install build-essential libpcre3 libpcre3-dev libssl-dev libxslt-dev -y cd \/tmp wget http:\/\/nginx.org\/download\/nginx-1.7.3.tar.gz wget https:\/\/github.com\/arut\/nginx-rtmp-module\/archive\/master.zip tar -zxvf nginx-1.7.3.tar.gz apt-get install unzip -y unzip master.zip cd nginx-1.7.3\/ .\/configure &#8211;with-http_ssl_module &#8211;with-http_xslt_module &#8211;add-module=..\/nginx-rtmp-module-master make make install cp \/tmp\/nginx-rtmp-module-master\/stat.xsl \/usr\/local\/nginx\/html\/ cp \/usr\/local\/nginx\/conf\/nginx.conf \/usr\/local\/nginx\/conf\/nginx.conf.bak echo &hellip; <a href=\"https:\/\/cowmanchiang.me\/wp\/?p=1045\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[64,82],"tags":[],"class_list":["post-1045","post","type-post","status-publish","format-standard","hentry","category-nginx","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1045","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1045"}],"version-history":[{"count":1,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1045\/revisions"}],"predecessor-version":[{"id":2020,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1045\/revisions\/2020"}],"wp:attachment":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1045"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1045"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1045"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}