Skip to content

Instantly share code, notes, and snippets.

View deardooley's full-sized avatar

Rion Dooley deardooley

View GitHub Profile
@deardooley
deardooley / gist:f5512a966ddad73b19eb
Created March 21, 2015 16:30
figexec - Bash script to add docker exec support for fig orchestrations
#!/bin/bash
######################################################################
#
# figexec
#
# Author: Rion Dooley <deardooley@gmail.com>
# Description:
# This script emulates the functionality one would expect if `docker exec`
# functionality were supported in fig. Simply run this from your project
@deardooley
deardooley / jsonpki.sh
Last active August 29, 2015 14:19
This is a utility script to serialize keys and passwords into strings that can be safely used as string values in JSON objects.
#!/bin/bash
#
# Name: jsonpki.sh
#
# Author: Rion Dooley - deardooley
#
# Description: This is a utility script to serialize keys and passwords into
# strings that can be included safely in json objects and sent to a remote
# server. There are surely other ways to do this, but this seems to work well
# in situations such as creating system descriptions for use in the Agave
@deardooley
deardooley / lamp-mysql-slurm-ftpd
Last active September 15, 2015 11:16
Docker Compose file for lamp, mysql, slurm, ftpd. Save as `docker-compose.yml` and change the hostname to your server or VM hostname. **Do not use this in production!!!**
web:
image: php:5.6-apache
hostname: docker.example.com
ports:
- "80:80"
- "443:443"
links:
- mysql
- ftpd
- slurm
@deardooley
deardooley / Dockerfile
Last active November 9, 2015 03:42
Quick test image for abaco that will document the date locally and make a webhook callout to a URL passed as the message to get a timestamp externally.
FROM alpine:latest
ADD start.sh /docker_entrypoint.sh
RUN chmod +x /docker_entrypoint.sh
CMD ["sh", "/docker_entrypoint.sh"]
@deardooley
deardooley / keybase.md
Created March 5, 2017 01:39
keybase.md

Keybase proof

I hereby claim:

  • I am deardooley on github.
  • I am deardooley (https://keybase.io/deardooley) on keybase.
  • I have a public key whose fingerprint is 5969 9C3F 1F93 B12C 3DCB 59F4 4486 8378 4860 6209

To claim this, I am signing this object:

@deardooley
deardooley / RUNBOOK.md
Created February 27, 2019 04:30 — forked from voxxit/RUNBOOK.md
Example of a solid run book/operations manual

Run Book / Operations Manual

  1. Table of Contents
  2. System Overview
    • Service Overview
    • Contributing Applications, Daemons, and Windows Services
    • Hours of Operation
    • Execution Design
    • Infrastructure and Network Design
    • Resilience, Fault Tolerance and High-Availability
@deardooley
deardooley / random_tree_gen.sh
Last active April 25, 2019 08:39
Shell script to generate a directory tree of randomized test data.
#!/usr/bin/env bash
# http://stackoverflow.com/questions/13400312/linux-create-random-directory-file-hierarchy
set -o errexit #abort if any command fails
usage() {
echo -n "$(basename $0) [OPTIONS]
This script creates a directory tree of random depth, width and file size. All parameters are
#!/bin/bash
#set -x
# Shows you the largest objects in your repo's pack file.
# Written for osx.
#
# @see http://stubbisms.wordpress.com/2009/07/10/git-script-to-show-largest-pack-objects-and-trim-your-waist-line/
# @author Antony Stubbs
# set the internal field spereator to line break, so that we can iterate easily over the verify-pack output
@deardooley
deardooley / brew install php@7.1
Created June 29, 2020 11:01
Installing the now deprecated Homebrew php@7.1 on macOS
To install the deprecated php@7.1 on macOS using Homebrew, run the following commands:
```bash
git -C "$(brew — repo homebrew/core)" checkout d541efc^ — Formula/php@7.1.rb
brew install php@7.1
pecl install xdebug
pecl install igbinary
pecl install redis
```
If you are using PHPStorm as your IDE, you can configure xdebug by removing the extension lines added to your php.ini file by default and adding the following files to the `/usr/local/homebrew/etc/php/7.1/conf.d` folder.
```ini
@deardooley
deardooley / README.md
Last active September 22, 2020 16:10
Applescript for Cisco VPN autologin on OSX

This is a little AppleScript utility for mac that will allow you to login to Cisco vpn without manually entering your password over and over again.

  1. Open Script Editor on your mac.
  2. Paste in the file contents.
  3. Update with your username, password, and vpn name.
  4. Save to disk somewhere it won't get accidentally deleted. (~/Library/Scripts/cisco-vpn.scpt).
  5. Add an alias to your environment to call the script whenever you want to login to vpn: alias vpnup='osascript ~/Library/Scripts/dmc-vpn.scpt'