Skip to content

Instantly share code, notes, and snippets.

View legout's full-sized avatar

Volker L. legout

View GitHub Profile
@legout
legout / update_changelog.sh
Created April 28, 2025 08:38
Auto update Changelog on version bump
#!/bin/bash
# Usage: ./update_changelog.sh <previous_tag> <new_version>
set -e
PREV_TAG="$1"
NEW_VERSION="$2"
if [ -z "$PREV_TAG" ] || [ -z "$NEW_VERSION" ]; then
from __future__ import absolute_import
import signal
import gevent
import gevent.pool
from rq import Worker
from rq.timeouts import BaseDeathPenalty, JobTimeoutException
from rq.worker import StopRequested, green, blue
from rq.exceptions import DequeueTimeout
@legout
legout / reset-docker.sh
Last active March 3, 2025 14:07
Docker Swarm reset
#!/bin/bash
# Safe Docker Swarm Reset Script
# This script safely disables Docker Swarm while preserving SSH connectivity
# and avoiding risky network operations
# Minimal error handling - continue on errors to prevent hanging
set +e
echo "======= Safe Docker Swarm Reset ======="
echo "This script will preserve SSH connectivity throughout the process"
@legout
legout / vpn-docker-swarm-setup.sh
Created March 3, 2025 13:34
Setup Docker Swarm and Wireguard VPN
#!/bin/bash
# WireGuard VPN Setup Script for Docker Swarm
# This script sets up a WireGuard VPN between multiple VPS servers
# Error handling
set -e
trap 'echo "Error on line $LINENO. Exiting."; exit 1' ERR
# Check if running as sudo/root
if [ "$(id -u)" -ne 0 ]; then
@legout
legout / secure-vps-setup-interactive.sh
Created December 20, 2024 11:13
Interactive secure VPS setup
#!/bin/bash
# Helper function for yes/no prompts
confirm() {
while true; do
read -p "$1 [y/N] " yn
case $yn in
[Yy]* ) echo "yes"; return 0;;
[Nn]* | "" ) echo "no"; return 1;;
* ) echo "Please answer yes or no.";;
@legout
legout / vps-setup.sh
Last active March 19, 2025 10:26
VPS setup
#!/bin/bash
#--------------------------------------------------------------------#
# NOTE:
#
# I have added an interactive version of this vps setup script.
#
# https://gist.github.com/legout/56ce53a0275413b4c98d01482ca52943
#
#--------------------------------------------------------------------#
@legout
legout / # octave - 2018-07-16_20-30-00.txt
Created July 23, 2018 17:59
octave on macOS 10.13.6 - Homebrew build logs
Homebrew build logs for octave on macOS 10.13.6
Build date: 2018-07-16 20:30:00