Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- user root;
- worker_processes 1;
- #error_log logs/error.log;
- #error_log logs/error.log notice;
- #error_log logs/error.log info;
- #pid logs/nginx.pid;
- events {
- worker_connections 1024;
- }
- http {
- include mime.types;
- default_type application/octet-stream;
- #log_format main '$remote_addr - $remote_user [$time_local] "$request" '
- # '$status $body_bytes_sent "$http_referer" '
- # '"$http_user_agent" "$http_x_forwarded_for"';
- #access_log logs/access.log main;
- sendfile on;
- #tcp_nopush on;
- #keepalive_timeout 0;
- keepalive_timeout 65;
- #gzip on;
- server {
- listen 80;
- server_name localhost;
- #charset koi8-r;
- #access_log logs/host.access.log main;
- location / {
- root html;
- index index.html index.htm;
- }
- #error_page 404 /404.html;
- # redirect server error pages to the static page /50x.html
- #
- error_page 500 502 503 504 /50x.html;
- location = /50x.html {
- root html;
- }
- # proxy the PHP scripts to Apache listening on 127.0.0.1:80
- #
- #location ~ \.php$ {
- # proxy_pass http://127.0.0.1;
- #}
- # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
- #
- #location ~ \.php$ {
- # root html;
- # fastcgi_pass 127.0.0.1:9000;
- # fastcgi_index index.php;
- # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
- # include fastcgi_params;
- #}
- # deny access to .htaccess files, if Apache's document root
- # concurs with nginx's one
- #
- #location ~ /\.ht {
- # deny all;
- #}
- }
- # another virtual host using mix of IP-, name-, and port-based configuration
- #
- #server {
- # listen 8000;
- # listen somename:8080;
- # server_name somename alias another.alias;
- # location / {
- # root html;
- # index index.html index.htm;
- # }
- #}
- # HTTPS server
- #
- #server {
- # listen 443 ssl;
- # server_name localhost;
- # ssl_certificate cert.pem;
- # ssl_certificate_key cert.key;
- # ssl_session_cache shared:SSL:1m;
- # ssl_session_timeout 5m;
- # ssl_ciphers HIGH:!aNULL:!MD5;
- # ssl_prefer_server_ciphers on;
- # location / {
- # root html;
- # index index.html index.htm;
- # }
- #}
- }
- rtmp {
- server {
- listen 1935;
- chunk_size 4000; # max size 16777215
- .
- ## Uncomment in case of frequent disconnections
- ## PacKoMMEHTuPyu ECJlu O6C 4ACTO OTKJll04AETC9\
- ping 1m;
- ping_timeout 10s;
- drop_idle_publisher 10s;
- .
- application receiver
- {
- live on;
- meta copy;
- ...................
- # This sends stream to transcoder
- push rtmp://localhost/transcoder/;
- .
- # Add source streams here you don't want to transcode
- .
- # Twitch source
- # push rtmp://live-fra.twitch.tv/app/************************;
- .
- # Youtube source
- # push rtmp://b.rtmp.youtube.com:1935/live2/************************;
- }
- .
- .
- application transcoder
- {
- live on;
- meta copy;
- .
- # 1080 all sites
- exec_push ffmpeg -i rtmp://localhost/transcoder/
- .
- -b:v 6000k
- -minrate 5500k
- -maxrate 6500k
- -bufsize 7000k
- .
- -vcodec libx264
- -preset faster
- -s 1920x1080
- -sws_flags bicubic
- .
- # -vf unsharp=3:3:1.5 # Video sharpening
- .
- -r 60
- -x264-params nal-hrd=cbr:force-cfr=1:keyint=120
- .
- -acodec aac
- -ab 160k
- -strict -2
- .
- -f flv rtmp://localhost/transcoded-1080/
- .
- # -loglevel verbose
- # 2>>/home/sneakyjoe/ffmpeg-log.txt
- ;
- .
- # 560 periscope
- # exec ffmpeg -i rtmp://localhost/transcoder/
- .
- # -b:v 740k
- # -minrate 600k
- # -maxrate 800k
- # -bufsize 800k
- .
- # -vcodec libx264
- # -preset fast
- # -s 960x540
- # -sws_flags lanczos
- .
- # -r 30
- # -x264-params nal-hrd=cbr:force-cfr=1:keyint=60
- .
- # -acodec aac
- # -ab 90k
- # -strict -2
- .
- # -f flv rtmp://localhost/transcoded-560/;
- }
- .
- application transcoded-1080
- {
- live on;
- meta copy;
- # Twitch transcoded
- push rtmp://live-fra.twitch.tv/app/live_39201175_Y6fMKfuE7oLrqlSnKnasxoq2xrDyj3;
- # youtube transcoded
- # push rtmp://b.rtmp.youtube.com:1935/live2/************************;
- # Restream.io transcoded
- # push rtmp://eu-east.restream.io/live/************************;
- # dailymotion transcoded
- # push rtmp://publish.dailymotion.com/publish-dm/************************;
- # Cybergame transcoded
- # push rtmp://premium.cybergame.tv:1953/************************;
- # GoodGame transcoded
- # push rtmp://msk.goodgame.ru:1940/live/************************;
- # Mixer (beam.pro) transcoded
- # push rtmp://ingest-fra.mixer.com:1935/beam/************************;
- ## This block will save your transcoded stream to record_path. Remember to create ~/RECS and do "chmod
- # recorder myrec
- # {
- # record all;
- # record_path /home/sneakyjoe/RECS; #Change sneakyjoe with your username
- # record_suffix _%Y.%m.%d___%H-%M___1080.flv;
- # }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement