Skip to content

Instantly share code, notes, and snippets.

View jthomaschewski's full-sized avatar

Janek Thomaschewski jthomaschewski

View GitHub Profile
@insdavm
insdavm / wireguard-over-tcp.md
Last active May 27, 2024 12:49
WireGuard over TCP with udptunnel

WireGuard over TCP with udptunnel

udptunnel is a small program which can tunnel UDP packets bi-directionally over a TCP connection. Its primary purpose (and original motivation) is to allow multi-media conferences to traverse a firewall which allows only outgoing TCP connections.

Server

# udptunnel -s 443 127.0.0.1/51820

Client

@xtavras
xtavras / kubernetes_add_service_account_kubeconfig.sh
Created November 25, 2019 10:54
create kubernetes service account and corresponding kubeconfig
#!/usr/bin/env bash
# script was taken from https://gist.github.com/innovia/fbba8259042f71db98ea8d4ad19bd708 and adjusted with "apply_rbac" function and colorized output
set -e
set -o pipefail
# Colors
RED="\e[01;31m"
@mumoshu
mumoshu / helmify-kustomize
Last active April 15, 2024 10:49
Run `helmify-kustomize build $chart $env` in order to generate a local helm chart at `$chart/`, from kustomize overlay at `${chart}-kustomize/overlays/$env`
#!/usr/bin/env bash
cmd=$1
chart=$2
env=$3
dir=${chart}-kustomize
chart=${chart/.\//}
build() {
@t-8ch
t-8ch / Makefile
Created January 31, 2018 22:10
minimal mutter application with window management
CFLAGS=$(shell pkg-config --cflags libmutter-1) -Wl,-rpath,/usr/lib/mutter
LDLIBS=$(shell pkg-config --libs libmutter-1)
all: main
@al3xtjames
al3xtjames / xps_9560_ifr.txt
Last active April 2, 2024 10:35
Dell XPS 15 9560 (1.2.5) NVRAM edits
# Set Intel(R) Speed Shift Technology to Enabled
setup_var 0x4BC 0x1
# Set CFG Lock to Disabled
setup_var 0x4ED 0x0
# Set Above 4GB MMIO BIOS assignment to Enabled
# setup_var 0x79A 0x1
# Set EHCI Hand-off to Disabled
# setup_var 0x2 0x0
# Set XHCI Hand-off to Disabled
@innovia
innovia / kubernetes_add_service_account_kubeconfig.sh
Last active January 29, 2024 23:00
Create a service account and generate a kubeconfig file for it - this will also set the default namespace for the user
#!/bin/bash
set -e
set -o pipefail
# Add user to k8s using service account, no RBAC (must create RBAC after this script)
if [[ -z "$1" ]] || [[ -z "$2" ]]; then
echo "usage: $0 <service_account_name> <namespace>"
exit 1
fi
@garsaud
garsaud / ProcessQueueAndExit.php
Last active October 18, 2021 18:14 — forked from jdforsythe/ProcessQueueAndExit.php
Laravel 5 Artisan Process Entire Queue and Exit Command
<?php
namespace App\Console\Commands;
use Exception;
use Throwable;
use Illuminate\Queue\Worker;
use Illuminate\Console\Command;
use Illuminate\Contracts\Queue\Job;
use Illuminate\Queue\WorkerOptions;
@LnL7
LnL7 / configuration.nix
Last active August 22, 2020 10:34
module replacement example
{ config, pkgs, ... }:
let
# Import unstable channel.
# sudo nix-channel --add http://nixos.org/channels/nixos-unstable nixos-unstable
unstable = import <nixos-unstable> {};
in
@cryzed
cryzed / fix-infinality.md
Last active May 27, 2024 18:14
A set of instructions on how to fix the harfbuzz + Infinality issue and restoring good-looking, Infinality-like font rendering.

Disclaimer: Please follow this guide being aware of the fact that I'm not an expert regarding the things outlined below, however I made my best attempt. A few people in IRC confirmed it worked for them and the results looked acceptable.

Attention: After following all the steps run gdk-pixbuf-query-loaders --update-cache as root, this prevents various gdk-related bugs that have been reported in the last few hours. Symptoms are varied, and for Cinnamon the DE fails to start entirely while for XFCE the icon theme seemingly can't be changed anymore etc.

Check the gist's comments for any further tips and instructions, especially if you are running into problems!

Screenshots

Results after following the guide as of 11.01.2017 13:08:

@pbabics
pbabics / gitlab-gc.sh
Created November 11, 2016 13:13
Manual garbage collector for gitlab registry, it removes old revisions that are not referenced by any tag
#!/bin/bash
BASE_PATH=/var/opt/gitlab/gitlab-rails/shared/registry/docker/registry/v2/repositories
DRY_RUN=0
KEEP_LAST_IMAGES=10
RUN_GARBAGE_COLLECTOR=0
GITLAB_CTL_COMMAND=`which gitlab-ctl`