Skip to content

Instantly share code, notes, and snippets.

@Raboo
Raboo / migrate-dockerhub-to-ghcr.sh
Last active December 14, 2022 21:58 — forked from charlieoleary/migrate-to-ecr.sh
Migrate your Docker Hub organization(docker.io) to Github Container Registry(ghcr.io).
#!/bin/bash
#
# A simple bash script to migrate your Docker Hub organization to Github Container Registry.
# forked from https://gist.github.com/charlieoleary/05c1dab2e19703f73a041e585e060dc9
#
# In order for this to work you must run this from a system that is logged in to both the GHCR
# repository you are migrating to and the Docker Hub organization you are migrating FROM with
# podman.
#
# Due to how Docker works (pulling / pushing images), this script can be run over and over
@Raboo
Raboo / sshuttle.sh
Last active May 24, 2023 13:09 — forked from rchrd2/sshuttle.sh
xbar + sshuttle
#!/usr/bin/env bash
#
# Easily start/stop sshuttle
#
# <xbar.title>sshuttle</xbar.title>
# <xbar.version>v1.3</xbar.version>
# <xbar.author>Elias Abacioglu</xbar.author>
# <xbar.author.github>Raboo</xbar.author.github>
# <xbar.desc>Easily start/stop a background sshuttle.</xbar.desc>
# <xbar.dependencies>sshuttle</xbar.dependencies>
#!/bin/bash
AMBARI_USER='admin'
AMBARI_PASSWORD='PWPWPW'
AMBARI_HOST='localhost'
CLUSTER_NAME='mitate'
MOVE_FROM='old-host.mitate.com'
MOVE_TO='new-host.mitate.com'
SSH_USER=john.doe
@Raboo
Raboo / haproxy_gmetric.rb
Last active October 27, 2015 10:30 — forked from macros/gist:553c2ef4d4b0594154f5
haproxy multi socket gmetric
#!/usr/bin/ruby
require 'socket'
abort('Upgrade ruby or die...') if RUBY_VERSION < "1.9"
pidfile = '/var/run/haproxy_gmetric.pid'
if File.exist?(pidfile)
pid = File.read(pidfile).to_i
begin
Process.kill(0, pid)
@Raboo
Raboo / temperature.sh
Last active August 29, 2015 14:07 — forked from fkleon/temperature.sh
FreeNAS 9 temperature script
#!/bin/sh
# Write some general information
echo System Temperatures - `date`
uptime | awk '{ print "\nSystem Load:",$10,$11,$12,"\n" }'
# Write CPU temperatures
echo "CPU Temperature:"
sysctl -a | egrep -E "cpu\.[0-9]+\.temp"