Skip to content

Instantly share code, notes, and snippets.

View OldCrowEW's full-sized avatar
👾
Working from 🏕️

John OldCrowEW

👾
Working from 🏕️
View GitHub Profile
@pjkelly
pjkelly / setup-vmware-image-with-static-IP.markdown
Created July 7, 2011 01:06
VMWare Fusion Images with a static IP Address on Mac OS X Snow Leopard

How to setup your VMWare Fusion images to use static IP addresses on Mac OS X

At Crush + Lovely, we use Railsmachine's Moonshine to automate the configuration of our servers. When writing our deployment recipes, VMWare Fusion's ability to take snapshots and rollback to these snapshots is a huge timesaver because it takes just seconds to roll a server image to it's original state.

When you're just configuring a single server, having a static IP address for your server image isn't too important, but when you're configuring multi-server setups, it can be useful to duplicate a number of server images and give each a static IP address so you can consistently deploy to them. While not documented well at all, it turns out that this is relatively easy to accomplish in four simple steps.

1. Determine the MAC address of your guest machine

Let's say you have a guest machine with the name ubuntu-lucid-lynx-base a

@fancyremarker
fancyremarker / .bash_login.jenkins
Last active March 6, 2023 19:21
[A.] Scripts related to Jenkins client setup
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
@marten-cz
marten-cz / selenium-hub.sh
Created November 6, 2012 13:30
Init scripts for linux to start Selenium Grid
#!/bin/bash
DESC="Selenium Grid Server"
RUN_AS="selenium"
JAVA_BIN="/usr/bin/java"
SELENIUM_DIR="/opt/selenium"
PID_FILE="$SELENIUM_DIR/selenium-grid.pid"
JAR_FILE="$SELENIUM_DIR/selenium-server.jar"
LOG_DIR="/var/log/selenium"
@plentz
plentz / nginx.conf
Last active May 17, 2024 09:08
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@gbirke
gbirke / install-java.yml
Created January 8, 2014 10:13
Ansible playbook for installing Oracle Java 7 on Debian
# Ansible playbook to install Java 7 on Debian
#
# Thanks to http://www.sysadminslife.com/linux/howto-oracle-sun-java-7-installation-unter-debian-6-squeeze/
#
# Author: Gabriel Birke <gb@birke-software.de>
- hosts: devroot
vars:
java_download: http://download.oracle.com/otn-pub/java/jdk/7u45-b18/jdk-7u45-linux-x64.tar.gz
java_name: jdk1.7.0_45
@nsbingham
nsbingham / local-dnsserver.md
Last active June 5, 2023 21:44
Testing a CNAME

Setting up a local DNS server with bind on OSX Mavericks

This is really just an approach for locally testing DNS changes, which can easily be done with a HOSTS file if the change involves an IP address, but gets a bit trickier when things like CNAMEs are involved. This is only meant to test locally off a single machine.

  1. Install bind using homebrew

    brew install bind

  2. Follow the installation steps to start up bind

@ruzickap
ruzickap / ovftool_installation.sh
Created September 27, 2014 13:37
OVFTool installation on ESXi
#Download OVF tools
wget -q ftp://ftp.example.com/software/vmware/installation_scripts/vmware-ovftool.tar.gz -O /vmfs/volumes/My_Datastore/vmware-ovftool.tar.gz
# Extract ovftool content to /vmfs/volumes/My_Datastore
tar -xzf /vmfs/volumes/My_Datastore/vmware-ovftool.tar.gz -C /vmfs/volumes/My_Datastore/
rm /vmfs/volumes/My_Datastore/vmware-ovftool.tar.gz
# Modify the ovftool script to work on ESXi
sed -i 's@^#!/bin/bash@#!/bin/sh@' /vmfs/volumes/My_Datastore/vmware-ovftool/ovftool
@likwid
likwid / ec2-instance__tasks__main.yml
Created March 11, 2015 16:12
"Idempotent" ec2 creation with ansible
---
- name: Find trusty ami for base image
ec2_ami_search:
distro: ubuntu
release: trusty
region: "{{ aws_region }}"
store: ebs-ssd
virt: hvm
register: ubuntu
when: not aws_ami_id is defined
---
# test SSH agent forwarding
- shell: echo "Client= [$SSH_CLIENT] Sock= [$SSH_AUTH_SOCK]"
sudo: no
register: myecho
- debug: msg="{{myecho.stdout}}"
- shell: ssh-add -l
sudo: no
register: myecho
- debug: msg="{{myecho.stdout}}"
@dcode
dcode / cobbler-pi.md
Created November 20, 2015 18:06
Cobbler Pi - Instructions for setting up cobbler on a Raspberry Pi

Requirements:

  • Raspberry Pi (I used the B+ model)
  • Enough hard drive space for install media (I mounted a 16 GB USB3 drive at /var/www/cobbler/)

Installation

The problem with installing cobbler on a Raspberry Pi, is that it depends on the syslinux package, which is not available for ARM architectures. More importantly, we specifically need the x86 version of syslinux anyway, because it provides the files that will be used to PXE boot systems (which in my case is x86_64 arch).