Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am pw10n on github.
  • I am pw10n (https://keybase.io/pw10n) on keybase.
  • I have a public key ASAf-2clBFPmgr8tTBnm7qnYmMW09V3OnXEbHwY2OGjt_wo

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am echo0101 on github.
  • I am pw10n (https://keybase.io/pw10n) on keybase.
  • I have a public key ASA4xyFmpgKf9Zt7ylakDTyovw9Tgda-qT7Ss8cIIeYkeAo

To claim this, I am signing this object:

apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: squid
spec:
replicas: 1
template:
metadata:
labels:
name: squid
@pw10n
pw10n / gist:f23d2b1d8177f7601bad
Created December 10, 2015 20:23
Stream ip cam video (rtsp) to youtube (rtmp)
Audio is required by YouTube otherwise the stream is rejected so we're adding an empty audio stream.
Video is already in a supported format so just passing through.
avconv -rtsp_transport tcp -i "rtsp://{SOURCE_URL}" -b:a 128k -f s16le -ar 44100 -ac 2 -i /dev/zero -codec:v copy -codec:a aac -f flv -strict experimental "rtmp://a.rtmp.youtube.com/live2/{STREAM_KEY}"
@pw10n
pw10n / .htaccess
Last active May 8, 2020 14:01
jpg frames to mjpeg in php
# Make PHP code look like mjpeg
AddType application/x-httpd-php .mjpeg
@pw10n
pw10n / gist:abc4a6425379a625cd99
Created May 6, 2015 18:51
Animate jpg frames in img folder
<!--
First iteration of animating jpg images found in image folder.
This is hosted on a shared host so limited to certain technologies for simplicity.
Some thoughts on where this could go next:
- break out imgFrames to separate php as an api allowing selectable ranges, etc
- use mjpeg instead of animating jpg frames on client
-->
<!doctype html>
<html>