Skip to content

Instantly share code, notes, and snippets.

View boyboi86's full-sized avatar
🙂
I may be slow to respond.

undefeated_ boyboi86

🙂
I may be slow to respond.
View GitHub Profile
@boyboi86
boyboi86 / ExampleModel.js
Created October 31, 2016 06:09 — forked from stephencoe/ExampleModel.js
Serve cached images from s3 instead of cloudinary. It needs tidying but it works and reduces bandwidth dramatically. - inspired by https://gist.github.com/dboskovic/23858511bf3c1cbebdbd
//...
Model.add({
content: {
type: Types.Html, wysiwyg: true, height: 400
},
hash : {
type : String,
hidden : true
},
@boyboi86
boyboi86 / html5-video-streamer.js
Created June 8, 2016 06:34 — forked from paolorossi/html5-video-streamer.js
Node.js HTML5 video streamer
/*
* Inspired by: http://stackoverflow.com/questions/4360060/video-streaming-with-html-5-via-node-js
*/
var http = require('http'),
fs = require('fs'),
util = require('util');
http.createServer(function (req, res) {
var path = 'video.mp4';