Skip to content

Instantly share code, notes, and snippets.

View flavioribeiro's full-sized avatar
:octocat:

Flavio Ribeiro flavioribeiro

:octocat:
View GitHub Profile
{
"streams": [
"eiplus": {
"input-path": "/live-stream-secure/5801255b39c38e1109ddfabd/publish/media_2500.m3u8?dnt=true&access_token=8UchcOwh4X0fsaceGvovudlTmr1XfIx8Y6o7V2W8Uu20cBpqnysoOa35lIrL48CXD5NjnspExCB&ref=https%3A%2F%2Fwww.eiplus.com.br%2Fcanal%2F45%2Fconexao-ei-ao-vivo%2F&es=vrzn-ei-ee.cdn.mdstrm.com&proto=https",
"servers": ["https://vrzn-ei-ee.cdn.mdstrm.com"],
}
]
}
location ~ ^/video-media/hlsfmp4/.+$ {
content_by_lua_block {
require "string";
function split(inputstr, sep)
if sep == nil then
sep = "%s"
end
local t={} ; i=1
for str in string.gmatch(inputstr, "([^"..sep.."]+)") do
worker_processes auto;
error_log stderr debug;
events {
worker_connections 1024;
multi_accept on;
use epoll;
}
### Keybase proof
I hereby claim:
* I am flavioribeiro on github.
* I am flavioribeiro (https://keybase.io/flavioribeiro) on keybase.
* I have a public key ASCYrTTnOAtFIBoZMn5WyVqdl3QQo4VvKtAgZZ57ftipGQo
To claim this, I am signing this object:
func (s *DistributionService) purge(files []string, logger *logrus.Logger) {
purge := func(path string) {
err := s.purger.Purge(path)
if err != nil {
logger.WithField("error", err).WithField("path", path).Error("failed to purge path")
}
}
if s.purger != nil && len(files) > 0 {
paths := make([]string, len(files))
for i, file := range files {
diff --git provider/provider.go provider/provider.go
index dcaa9e6..05c5692 100644
--- provider/provider.go
+++ provider/provider.go
@@ -94,6 +94,7 @@ type OutputFile struct {
VideoCodec string `json:"videoCodec"`
Height int64 `json:"height"`
Width int64 `json:"width"`
+ FileSize int64 `json:"fileSize"`
}
package service
import (
"encoding/json"
"errors"
"net/http"
"net/http/httptest"
"reflect"
"regexp"
"runtime"
[core]
editor = /usr/bin/vim
pager = diff-highlight | diff-so-fancy | less --tabs=1,5 -R
[alias]
cm = commit -m
st = status --short
co = checkout
logg = log --graph --color --decorate
loga = log --graph --color --pretty='format:%C(yellow)%h%C(cyan)%d %Creset %s %C(blue)%an, %ar' --date-order --all
logt = log --graph --color --pretty='format:%C(yellow)%h%C(cyan)%d %Creset %s %C(blue)%an, %ar' --date-order
diff --git bump.sh Users/207112/golang/src/github.com/NYTimes/video-transcoding-api/bump.sh
index cc26af4..443e185 100755
--- bump.sh
+++ Users/207112/golang/src/github.com/NYTimes/video-transcoding-api/bump.sh
@@ -1,8 +1,8 @@
#!/bin/bash
PROJECT=$(git config --local remote.origin.url|sed -n 's#.*/\([^.]*\)\.git#\1#p')
-GH_LOG_TEMPLATE="([%h](https://github.com/nytm/$PROJECT/commit/%h)) %s %n"
-EMAIL_LOG_TEMPLATE="[<a href=https://github.com/nytm/$PROJECT/commit/%h>%h</a>] %s - by %an, %ci.<br>"
{
"providers": ["zencoder"],
"preset": {
"name": "QA_zencoder_mp4_vbr2",
"description": "preset_zencoder_mp4_vbr for QA.",
"container": "mp4",
"rateControl": "VBR",
"video": {
"profile": "Main",
"profileLevel": "3.1",