Skip to content

Instantly share code, notes, and snippets.

View zburgermeiszter's full-sized avatar
👨‍💻
Available for Remote DevOps Engineer positions

Zoltan Burgermeiszter zburgermeiszter

👨‍💻
Available for Remote DevOps Engineer positions
View GitHub Profile
@zburgermeiszter
zburgermeiszter / export-k8s.sh
Last active April 19, 2024 21:49
Export all resources from Kubernetes (k8s) clusters. Resources are exported to separate folders and files by namespace and API name.
#!/bin/bash
backup_folder="kubernetes_backup"
# Create a directory to store the backup
mkdir -p $backup_folder
# Get a list of all resource resources, including both namespaced and non-namespaced resources
resources=$(kubectl api-resources --verbs=list -o name)
# Get a list of all namespaces
@zburgermeiszter
zburgermeiszter / linux-fake-webcam-loop.sh
Created December 29, 2015 21:48
Loop video file as fake webcam device with ffmpeg
ffmpeg -re -f concat -i <(for i in {1..9999}; do printf "file '%s'\n" input.mp4; done) -f v4l2 /dev/video1 && !!
cat ~/.ssh/id_rsa.pub | ssh -i aws.pem ubuntu@ip_address "cat - >> ~/.ssh/authorized_keys"
@zburgermeiszter
zburgermeiszter / functions.tf
Created October 19, 2023 14:17 — forked from carlessanagustin/functions.tf
Terraform functions by example
##--------------------------
## Terraform: Functions ##
##--------------------------
## Open terraform console
terraform console
#######################
## Numeric Functions ##
#######################
@zburgermeiszter
zburgermeiszter / hddled.sh
Created June 22, 2015 11:09
HDD led on Scroll Lock
#!/bin/bash
# Check interval seconds
CHECKINTERVAL=0.05
# console
CONSOLE=/dev/console
#indicator to use [caps, num, scroll]
INDICATOR=scroll
@zburgermeiszter
zburgermeiszter / envsubst-multi.sh
Created December 14, 2017 11:28
Envsubst render multiple files.
for f in $(find deploy/templates -regex '.*\.ya*ml'); do envsubst < $f > "./deploy/generated/$(basename $f)"; done
@zburgermeiszter
zburgermeiszter / Base64.php
Last active August 9, 2022 19:04
TWIG Base64 extension for Symfony
<?php
namespace Vendor\Bundle\Twig;
/*
services.yml:
twig.base64:
class: Vendor\Bundle\Twig\Base64
tags :
- { name: twig.extension }
@zburgermeiszter
zburgermeiszter / import.sh
Created April 7, 2016 12:55
Import sql file to MariaDB in Docker
docker exec -i CONTAINER_ID /bin/bash -c "export TERM=xterm && mysql -proot -uroot database" < import.sql
@zburgermeiszter
zburgermeiszter / crypttab
Created September 11, 2021 23:53 — forked from tjvr/crypttab
Hibernate on Ubuntu 18.04 with LVM full-disk encryption
sda5_crypt UUID=c66880c1-c2f1-40fc-9580-f25d493876ef none luks,discard
@zburgermeiszter
zburgermeiszter / install_postman.sh
Created September 7, 2021 18:12 — forked from pil0u/install_postman.sh
Install Postman on Linux through CLI without Snap
# This script basically automates the official Postman installation guide for Linux:
# https://learning.postman.com/docs/getting-started/installation-and-updates/#installing-postman-on-linux
# 32 or 64-bit?
BIT=$(getconf LONG_BIT)
# Download the appropriate version
wget -O ~/postman.tar.gz "https://dl.pstmn.io/download/latest/linux${BIT}"
# Extract the archive in /opt