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
#!/usr/bin/env node | |
//Replace following vars: | |
var base_url = "http://ELEMENTAL-NAME.YOURDOMAIN.ccc"; | |
var user_name = "PUT ELEMENTAL YOUR USERNAME"; | |
var api_key = "PUT YOUR ELEMENTAL API KEY"; | |
var ev_number = EV_NUMBER_TO_SW; //Example: 33 | |
var input_name_to_switch = "INPUT NAME"; //The input's name on elemental. Example: slate | |
const child_process = require('child_process'); |
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
#!/usr/bin/env node | |
const dns = require('dns'); | |
const options = { | |
ttl: true | |
}; | |
if (process.argv.length < 4) { | |
console.error("Usage dns-propagation-time-check.js domain ip_target"); |
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
#Generate HLS chunklist with AES128 chunk encryption file | |
#Source data | |
SOURCE="/Users/jcenzano/Movies/test10m_baseline_30_320x240_a25fpsB.mp4" | |
#Dest data | |
DEST="/Users/jcenzano/Movies/hls-encrypted/result-aes128" | |
KEYS_DIR="keys" | |
DEST_KEYS=$DEST"/"$KEYS_DIR |
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
#Generate fairplay file with random generated Key, IV. | |
#And generate also a trobleshooting chunklist bypassing fairplay server and providing the plain key for testing | |
#Source data | |
SOURCE="/Users/jcenzano/Movies/test10m_baseline_30_320x240_a25fpsB.mp4" | |
#Dest data | |
DEST="/Users/jcenzano/Movies/hls-encrypted/result-fairplay" | |
KEYS_DIR="keys" | |
KEY_IV_FILENAME="key-iv.bin" |
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
#!/usr/bin/env node | |
const AWS = require('aws-sdk'); | |
const crypto = require('crypto'); | |
const http = require('http'); | |
const stream = require('stream'); | |
const Readable = stream.Readable; | |
//Stream reader | |
class streamFromData extends Readable { |
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/sh | |
#Prerequirsites | |
sudo yum update | |
sudo yum install autoconf automake bzip2 cmake freetype-devel gcc gcc-c++ git libtool make mercurial pkgconfig zlib-devel tcl openssl-devel | |
#prepare/cleanup environment | |
cd ~ | |
rm -rf ~/ffmpeg_build ~/ffmpeg_sources ~/bin/{ffmpeg,ffprobe,ffserver,lame,vsyasm,x264,yasm,ytasm} | |
mkdir ~/ffmpeg_sources |
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
#!/usr/bin/env node | |
const AWS = require('aws-sdk'); | |
const http = require('http'); | |
//Data from TOKIO region | |
//Upload data | |
const upload_tokio = { | |
bucketName: 'XX', |
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
#!/usr/bin/env node | |
const https = require('https'); | |
if (process.argv.length !== 6) { | |
console.error("Use: ./jaws-ingest.js hls_asset_url client_id client_secret VC_account_id"); | |
return 1; | |
} | |
function httpReq (method, host, path, headers, body, callback) { | |
let answer_raw = []; |
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
#!/usr/bin/env node | |
const AWS = require('aws-sdk'); | |
AWS.config.update({region: 'us-west-2'}); | |
const dynamodb = new AWS.DynamoDB({ apiVersion: '2012-08-10' }); | |
let dbparams_q1 = { | |
"TableName": "alive-qa-brain-ddb-tbllivejobs", | |
"IndexName": "account_id-job_created_at-index", |
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
#!/usr/bin/env bash | |
# Assumimng input .ts with 2 tracks: | |
# Video: h264 | |
# Audio: AAC | |
# Check ffmpeg and BENTO mp4extract are installed and in the PATH | |
if ! [ -x "$(command -v ffmpeg)" ]; then | |
echo 'Error: ffmpeg is not installed.' >&2 |
OlderNewer