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
FROM golang:1.17 as builder | |
WORKDIR /go/src/app | |
COPY go.mod . | |
COPY go.sum . | |
RUN go mod download | |
COPY main.go . | |
RUN CGO_ENABLED=0 go build -a -installsuffix cgo -ldflags "-w -s" -o app | |
FROM scratch | |
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt |
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
# add to /etc/udev/rules.d/70-persistent-net.rules | |
# replace xx:xx:xx:xx:xx:xx with actual mac address and adjust the name (eth0). repeat line for every interface. | |
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:xx:xx:xx:xx:xx", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0" |
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
import java.io.File; | |
import java.util.LinkedList; | |
import java.util.List; | |
public class SearchFile { | |
public static void main(String[] args) { | |
// Liste aller Funde | |
LinkedList<String> results = new LinkedList<>(); |
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 python3 | |
""" Usage: helm template ... | python thisscript.py """ | |
import sys | |
import yaml | |
import subprocess | |
docs = yaml.load_all(sys.stdin, Loader=yaml.Loader) | |
# get all objects names of kind Deployment, DaemonSet, StatefulSet | |
for doc in docs: |
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
autodetach on # default: on | |
crlf off # default: off | |
deflogin off # default: on | |
hardcopy_append on # default: off | |
startup_message off # default: on | |
vbell on # default: ??? | |
termcapinfo xterm ti@:te@ | |
defscrollback 1000 # default: 100 | |
caption always "%{gk}%?%-Lw%?%{Gk}%n*%f %t%?(%u)%?%{gk}%?%+Lw%? %82=%{gk}%M %d %92=%{gk}%c%=" | |
sorendition kG # black on bold green |
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
reaktorbeamer() { | |
xrandr --newmode "1920x1080_60.00" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync | |
xrandr --addmode VGA1 1920x1080_60.00 | |
xrandr --output LVDS1 --mode 1366x768 --scale 1x1 --output VGA1 --mode 1920x1080_60.00 --scale 0.7x0.7 | |
} | |
# scale and resolution of LVDS might need to be adjusted |
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
! remove CapsLock, as nobody needs it | |
remove Lock = Caps_Lock | |
! reconfigure CapsLock as switch, s.t. it activates | |
! umlauts on a, o, u, s | |
keycode 66 = Mode_switch | |
keycode 26 = e E EuroSign cent | |
keycode 30 = u U udiaeresis Udiaeresis | |
keycode 32 = o O odiaeresis Odiaeresis | |
keycode 38 = a A adiaeresis Adiaeresis | |
keycode 39 = s S ssharp |
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
*filter | |
:INPUT DROP [0:0] | |
:FORWARD DROP [0:0] | |
:OUTPUT ACCEPT [0:0] | |
-A INPUT -i lo -j ACCEPT | |
-A INPUT -m rt --rt-type 0 -j DROP | |
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT | |
-A INPUT -m conntrack --ctstate INVALID -j DROP | |
-A INPUT -p ipv6-icmp -m icmp6 --icmpv6-type 1 -j ACCEPT | |
-A INPUT -p ipv6-icmp -m icmp6 --icmpv6-type 2 -j ACCEPT |
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
1. Test 123 | |
This some quite | |
```` | |
make | |
```` | |
And this? | |
``` | |
make install |
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
" ~/.config/nvim/init.vim | |
" | |
" After add / remove Plugins, run :PlugInstall / :PlugClean | |
if has('nvim') | |
let $VIMHOME = '~/.config/nvim' | |
else | |
let $VIMHOME = '~/.vim' | |
endif |