Skip to content

Instantly share code, notes, and snippets.

View booyaa's full-sized avatar
🏠
Working from home forevah!

Mark Sta Ana booyaa

🏠
Working from home forevah!
View GitHub Profile
@ghoulmann
ghoulmann / SteamOS_VB.sh
Created December 18, 2013 23:06
Downloads SteamOS.zip, creates ISO, installs virtualbox 4.2 & dkms, and creates virtual machine for user with boot ISO attached and EFI enabled. Requires: Ubuntu, internet, sudo access...
#!/bin/bash -e
#Set up customizeable variables
VM='SteamOS' #the name of the vm
TRASH="/tmp" #where to dump the zip and decompressed folder
ISO="steamos-1.0-uefi-amd64.iso" #what to call the iso
PUT="/tmp" #where to put the iso
VDI=$(pwd) #where to put the virtual drive
@torumakabe
torumakabe / hpcos_vboxsetup_controller.sh
Created January 4, 2014 13:28
Creare VirtualBox VM for HP Cloud OS Sandbox 1.20 controller node
#!/bin/sh
VBoxManage createvm --name "controller" --ostype Ubuntu_64 --register
VBoxManage modifyvm "controller" --cpus 1
VBoxManage modifyvm "controller" --memory 4096
VBoxManage modifyvm "controller" --nic1 hostonly
VBoxManage modifyvm "controller" --hostonlyadapter1 vboxnet0
VBoxManage modifyvm "controller" --nictype1 Am79C973
VBoxManage modifyvm "controller" --nicpromisc1 allow-all
VBoxManage modifyvm "controller" --nic2 intnet
@ismasan
ismasan / sse.go
Last active February 27, 2025 00:15
Example SSE server in Golang
// Copyright (c) 2017 Ismael Celis
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included in all
@mattjmorrison
mattjmorrison / chess_clock.sh
Created October 3, 2014 02:44
Tmux Chess Clock Pairing
#!/bin/bash
`tmux set-option -g display-time 2000`
IFS=$'\n'
CLIENTS=()
for CLIENT in $(tmux list-clients); do
CLIENTID="${CLIENT%:*}"
if [[ $CLIENT == *\(ro\) ]]
then
@segrax
segrax / CreateFreeBSDVm.sh
Last active September 8, 2020 16:05
Create a FreeBSD 64bit VM with VirtualBox, on FreeBSD, Accepting VNC Connections
# Create a VM named 'MyBSDBox' (64 bit FreeBSD)
VBoxManage createvm --ostype FreeBSD_64 --register --basefolder /vms --name MyBSDBox
# 1gig of memory, 1 CPU.. and set the network to bridged via EM0, emulating the 82540EM chipset
VBoxManage modifyvm MyBSDBox --memory 1024 --ioapic on --cpus 1 --chipset ich9 --nic1 bridged --nictype1 82540EM --bridgeadapter1 em0
# 20 gig Dynamic HDD image, on sata controller
VBoxManage createhd --size 20000 --filename "/vms/MyBSDBox/MyBSDBox.vdi"
VBoxManage storagectl MyBSDBox --name "SATA Controller" --add sata --controller IntelAhci --portcount 4
VBoxManage storageattach MyBSDBox --storagectl "SATA Controller" --port 0 --device 0 --type hdd --medium "/vms/MyBSDBox/MyBSDBox.vdi"
@md5
md5 / 00_README.md
Last active May 11, 2025 13:13
Demonstration Docker config for Wordpress on PHP-FPM behind Nginx

Proof of concept setup for Wordpress running under PHP-FPM with an Nginx frontend

Usage

Build a copy of this image:

git clone git://github.com/d9206eacb5a0ff5d6be0.git docker-nginx-fpm
cd docker-nginx-fpm
docker build -t nginx-fpm .
#! /bin/sh
# $Id$
# This script should be run as a cron job on a regular interval. It will
# perform several system checks such as available disk space, free physical
# RAM check, and check logical drives' status/state.
MEGACLI="/opt/sbin/MegaCli64"
ARCCONF="/opt/sbin/arcconf"
@paniq
paniq / pico8.txt
Last active October 5, 2024 06:12
PICO-8 hacks & secrets
Screen resolutions
------------------
PICO-8 supports different undocumented videomodes that can be activated at runtime,
using poke(0x5F2C, X) where X is one of the following mode numbers:
0: 128x128, 0 pages
1: 64x128, 1 page
2: 128x64, 1 page
3: 64x64, 3 pages
@voxxit
voxxit / USING-VAULT.md
Last active July 7, 2022 03:02
Consul + Vault + MySQL = <3
git clone https://gist.github.com/dd6f95398c1bdc9f1038.git vault
cd vault
docker-compose up -d
export VAULT_ADDR=http://192.168.99.100:8200

Initializing a vault:

vault init
@nathanleclaire
nathanleclaire / bootstrap-multihost.sh
Last active September 27, 2020 17:56
Script to bootstrap multihost swarm with Docker Machine (DIGITALOCEAN_ACCESS_TOKEN env var must be set, and experimental client binary available as dockerx locally)
#!/bin/bash
set -e
# Create this many swarm workers
export N_WORKERS=1
# Coloring info
export bold=$(tput bold)
export normal=$(tput sgr0)