Skip to content

Instantly share code, notes, and snippets.

View Ullaakut's full-sized avatar

Brendan Le Glaunec Ullaakut

View GitHub Profile
@Ullaakut
Ullaakut / genesis_public_key
Created February 8, 2018 14:59
genesis_public_key
04b60b63498df121975ab114ccd52f739eb49dddc7f1494ff0a49c7f917333e51b851c3b805dc8f8351bcf5cc03d612737e90ed4e5fb653b230adebfb5e65b229b
@Ullaakut
Ullaakut / flatten.go
Last active March 15, 2018 16:22
Flatten integers
package utils
// FlattenIntegers flattens nested slices of integers
func FlattenIntegers(slice []interface{}) []int {
var flat []int
for _, element := range slice {
switch element.(type) {
case []interface{}:
flat = append(flat, FlattenIntegers(element.([]interface{}))...)
@Ullaakut
Ullaakut / credentials.json
Created March 15, 2018 20:33
Default RTSP credentials for IP cameras
{
"usernames": [
"",
"admin",
"Admin",
"Administrator",
"root",
"supervisor",
"ubnt",
"service",
docker run --rm -p 8554:8554 ullaakut/rtspatt

Keybase proof

I hereby claim:

  • I am ullaakut on github.
  • I am ullaakut (https://keybase.io/ullaakut) on keybase.
  • I have a public key ASD76pw250ZsBqI_4FMAgpUmaz5ngr5CdSfJJCtWfyn7awo

To claim this, I am signing this object:

@Ullaakut
Ullaakut / controller.scpt
Last active October 17, 2018 09:45
The applescript code for the travisCI widgets
# Replace those with your repository IDs
set BloggoID to "20418060"
set CameradarID to "10999701"
set RTSPattID to "10999702"
set GonveyID to "21157116"
# Gets status from Travis API
on getStatus(repositoryID)
set status to do shell script "curl -v -H \"Travis-API-Version: 3\" \"https://api.travis-ci.org/repo/" & repositoryID & "/builds?limit=1\" | grep -Eo '\"state\":.*?[^\\]\",' | awk -F':' '{print $2}' | sed 's/[\", ]//g'"
return status
@Ullaakut
Ullaakut / service.yaml
Created July 1, 2019 14:36
Rate limited service
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: myservice
namespace: traefikee
labels:
app: myservice
annotations:
traefik.ingress.kubernetes.io/rate-limit: |
extractorfunc: client.ip
@Ullaakut
Ullaakut / service.yaml
Created October 4, 2019 06:17
Connection limiting in TraefikEE
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: myservice
namespace: traefikee
labels:
app: myservice
annotations:
traefik.ingress.kubernetes.io/max-conn-amount: "10"
traefik.ingress.kubernetes.io/max-conn-extractor-func: client.ip
cvlc /home/ullaakut/Downloads/dummy.jpg -I dummy \
--sout-keep --no-drop-late-frames --no-skip-frames \
--image-duration 9999 \
--sout="#transcode{vcodec=h264,fps=15,venc=x264{preset=ultrafast,tune=zerolatency,keyint=30,bframes=0,ref=1,level=30,profile=baseline,hrd=cbr,crf=20,ratetol=1.0,vbv-maxrate=1200,vbv-bufsize=1200,lookahead=0}}:rtp{sdp=rtsp://:8554/live.sdp}" \
--sout-all
@Ullaakut
Ullaakut / test.md
Last active June 18, 2021 09:18
test.md

Blocks

f56720620cb12515e09ee29385435f46be1c20437156bca5856753db247b8703