Skip to content

Instantly share code, notes, and snippets.

Avatar

Jan Koppe JanKoppe

View GitHub Profile
View gist:140642d3d0e290d78416c83548a65fef
$ LIBVA_DRIVER_NAME=i965 ffmpeg -y -init_hw_device qsv=hw -filter_hw_device hw -f decklink -i 'DeckLink Quad HDMI Recorder (1)' -vf hwupload=extra_hw_frames=64,format=qsv -c:v h264_qsv -b:v 5M output.mp4
ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 10.2.0 (GCC)
configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-avisynth --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libmfx --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librav1e --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --e
@JanKoppe
JanKoppe / DesktopVideoUpdateTool
Last active Oct 19, 2020
ffmpeg-no-decklink-sources
View DesktopVideoUpdateTool
# DesktopVideoUpdateTool -la
Available Devices:
* DeckLink Quad HDMI Recorder (Gc0272b0)
Firmware is up to date
@JanKoppe
JanKoppe / README.md
Last active Jul 6, 2020
nginx basic auth with different users for read/write
View README.md

This nginx configuration allows to restrict access via different methods to separate users.

This is very useful for private docker registries, where you want every member of your team to be able to fetch Docker images, but only some users (admins and CI users) to push new images to the registry.

Example:

  • User write can use GET, POST, PUT, DELETE and everything else.
  • User read can only use GET and HEAD.
  • Anonymous users are denied access entirely.
@JanKoppe
JanKoppe / gist:96dc92564f223e86e21e28a66523518b
Last active Apr 15, 2020
ugly POC to get billable seconds per project for a gitlab runner from the api
View gist:96dc92564f223e86e21e28a66523518b
import gitlab
from datetime import datetime, timedelta
import dateutil.parser
import pytz
import pprint
import os
BILLING_PERIOD_DAYS=7
@JanKoppe
JanKoppe / README.md
Last active Dec 9, 2019
36C3: Pretalx XML filter out track
View README.md
@JanKoppe
JanKoppe / mactab
Created Oct 12, 2016
Persistent network device naming with Alpine Linux
View mactab
#/etc/mactab
---
lan0 00:11:22:33:44:01
wan0 00:11:22:33:44:02
@JanKoppe
JanKoppe / 1001.conf
Created Jul 2, 2019 — forked from blha303/1001.conf
Asterisk 1.0.0.1 context
View 1001.conf
[1001]
exten => _X.,1,Set(CALLERID(name)=1.0.0.1)
exten => _X.,n,Answer
exten => _X.,n,Wait(1)
exten => _X.,n,Playback(1001-recordtype) ; "Enter record type on your phone keypad, followed by the hash key. Press 1 to go to next character"
exten => _X.,n,Read(recordtype,,,si,)
exten => _X.,n,Playback(1001-domain) ; "Enter domain name to retrieve record, followed by the hash key"
exten => _X.,n,Read(domain,,,si,)
exten => _X.,n,Set(RECORD="${SHELL(/usr/bin/1001.py "${recordtype}")}")
exten => _X.,n,Set(ADDR="${SHELL(/usr/bin/1001.py "${domain}")}")
@JanKoppe
JanKoppe / group_vars_all.ayml
Created May 27, 2019
Ansible Templating issue
View group_vars_all.ayml
test:
multiline: |
f4x6aaBtLPQk898Ymfkn
TQsi69wDY40aluFbdp99
jqdGOkx9CN2xgWOM8JeI
M4lXnXyctLTDejDb2eZu
XBPmvqXJStQFZIQwHzLF
by0cxOYjrY3On6hj3oqk
Xu0Ze6Sz8EbC7udHsyxE
jNv0M7lWNJCfegOlDCJH
@JanKoppe
JanKoppe / .gitignore
Created May 2, 2019 — forked from smoser/.gitignore
cloud-init ubuntu nocloud example with network config
View .gitignore
*.img
*.raw
@JanKoppe
JanKoppe / howToModifyOvaFile.md
Created May 2, 2019 — forked from goodjob1114/howToModifyOvaFile.md
how to modify .ova file on linux/Mac using terminal....export vm (OVF 1.0) from virtualbox, then modify some tag and hash value for import vm to ESXi
View howToModifyOvaFile.md

extract ova files from an archive

$ tar -xvf vmName.ova

modify ovf for some invalid tag

$ vi vmName.ovf
You can’t perform that action at this time.