This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<iframe | |
src="https://player.brime.tv/?channel=churrho" | |
height="400" | |
width="800" | |
frameBorder="0" | |
allowfullscreen="true" | |
allow="autoplay"> | |
</iframe> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worker_processes 1; #should be 1 for Windows, for it doesn't support Unix domain socket | |
#worker_processes auto; #from versions 1.3.8 and 1.2.5 | |
#worker_cpu_affinity 0001 0010 0100 1000; #only available on FreeBSD and Linux | |
#worker_cpu_affinity auto; #from version 1.9.10 | |
error_log /var/log/nginx/error.log error; | |
#if the module is compiled as a dynamic module and features relevant | |
#to RTMP are needed, the command below MUST be specified and MUST be |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo curl https://gist.githubusercontent.com/geekenMD/7d8a1c5bf242c824fdebbdb5ad5c423a/raw/126faa39260e553d3fb00c74d34bad5e7b0b23ae/webook-start.sh -o /etc/nginx/webook-start.sh | |
sudo curl https://gist.githubusercontent.com/geekenMD/732582dab5528b45e8573d1b818c0926/raw/caf47725b5a633a3c15c101f8940f4a1dcc25757/webook-stop.sh -o /etc/nginx/webook-stop.sh | |
sudo curl https://gist.githubusercontent.com/geekenMD/c6b625515e3ba2b75c0a5ab38c0ec37f/raw/3449050f30ec81d6d0610a1decf8deaa62d3b666/vod-processor.sh -o /etc/nginx/vod-processor.sh | |
sudo curl https://github.com/mutschler/mt/releases/download/1.0.11/mt-1.0.11-linux_amd64.tar.gz -o /etc/nginx/sprite | |
sudo chown -R nginx:nginx /etc/nginx |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
channel=$1 | |
dirname=$2 | |
filename=$3 | |
basename=$4 | |
event="vod-ready" | |
vod_id=$(curl https://internal-api.brime.tv/ID) | |
# Convert .flv to .mp4 | |
ffmpeg -y -i $dirname/$filename -c copy $dirname/${basename}.mp4 2> ${dirname}/test.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
channel=$1 | |
timestamp="$(date +%s)" | |
action="stream-stop" | |
json='{"action":"'"$action"'","channel":"'"$channel"'","timestamp":"'"$timestamp"'"}' | |
curl -X POST -H "Content-Type: application/json" -d $json https://internal-api.brime.tv/webhook/stream/stop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
channel=$1 | |
ip=$2 | |
region=sanjose | |
ingest_node="sanjose-001" | |
server="150.230.40.161" | |
timestamp="$(date +%s)" | |
action="stream-start" | |
json='{"action":"'"$action"'","channel":"'"$channel"'","ip":"'"$ip"'","region":"'"$region"'","ingest_node":"'"$ingest_node"'","server_IP":"'"$server"'","timestamp":"'"$timestamp"'"}' | |
curl -X POST -H "Content-Type: application/json" -d $json https://internal-api.brime.tv/webhook/stream/start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worker_processes 1; #should be 1 for Windows, for it doesn't support Unix domain socket | |
#worker_processes auto; #from versions 1.3.8 and 1.2.5 | |
#worker_cpu_affinity 0001 0010 0100 1000; #only available on FreeBSD and Linux | |
#worker_cpu_affinity auto; #from version 1.9.10 | |
error_log /var/log/nginx/error.log error; | |
#if the module is compiled as a dynamic module and features relevant | |
#to RTMP are needed, the command below MUST be specified and MUST be |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt update && sudo apt upgrade -y | |
sudo apt install -y software-properties-common ufw | |
sudo apt install -y build-essential git tree | |
wget https://nginx.org/download/nginx-1.19.0.tar.gz && tar zxvf nginx-1.19.0.tar.gz | |
# PCRE version 8.44 | |
wget https://ftp.pcre.org/pub/pcre/pcre-8.44.tar.gz && tar xzvf pcre-8.44.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/var/log/nginx/*.log { | |
daily | |
missingok | |
rotate 52 | |
compress | |
delaycompress | |
notifempty | |
create 640 nginx adm | |
sharedscripts | |
postrotate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=nginx - high performance web server | |
Documentation=https://nginx.org/en/docs/ | |
After=network-online.target remote-fs.target nss-lookup.target | |
Wants=network-online.target | |
[Service] | |
Type=forking | |
PIDFile=/var/run/nginx.pid | |
ExecStartPre=/usr/sbin/nginx -t -c /etc/nginx/nginx.conf |
NewerOlder