Skip to content

Instantly share code, notes, and snippets.

##Dockerfile
FROM centos:7
RUN yum update -y && yum install -y wget perl openssl-devel dmidecode sed vim
RUN wget -q -O - http://linux.dell.com/repo/hardware/latest/bootstrap.cgi | bash
# Edit /etc/yum.repos.d/dell-system-update.repo to point to last supported centos 7 version
RUN sed -i '/\[dell-system-update_independent\]/a baseurl=https://linux.dell.com/repo/hardware/DSU_22.08.12/os_independent/' /etc/yum.repos.d/dell-system-update.repo
RUN sed -i 's|baseurl=https://linux.dell.com/repo/hardware/dsu/os_independent/|#&|' /etc/yum.repos.d/dell-system-update.repo
@duckworth
duckworth / export.sh
Created July 7, 2022 15:48 — forked from JCotton1123/export.sh
AWS Export IP Addresses
# Export IP addresses to support vulnerability scanning
# Public IPs
touch /tmp/public-ips.txt
aws ec2 describe-instances \
--query "Reservations[*].Instances[*].PublicIpAddress" \
--output=text \
>>/tmp/public-ips.txt
@duckworth
duckworth / install.sh
Last active December 11, 2020 14:24 — forked from mkubenka/install.sh
OpenVPN Access Server Letsencrypt
#!/bin/sh
apt-get -y install socat
curl https://get.acme.sh | sh
@duckworth
duckworth / pgbackup
Last active August 16, 2019 13:46
basic pgbackup and pgrestore command utlitites used during local development to quickly save and restore local databases
#!/bin/bash
backupdir="$HOME/dbbackups";
day=`date -u +"%Y-%m-%d"`;
mkdir -p $backupdir/$day;
echo "PostgreSQL Backup util on $HOSTNAME";
echo "================================="
echo `date`;
for database in `/usr/local/bin/psql -lt | awk '{print $1}' | grep -vE '\||^$|template[0-9]'`;
@duckworth
duckworth / alb.sql
Created December 20, 2016 19:56
AWS ALB Logs Athena RegexSerDe
CREATE EXTERNAL TABLE IF NOT EXISTS alb_logs (
type string,
timestamp string,
elb string,
client_ip string,
client_port int,
target_ip string,
target_port int,
request_processing_time double,
target_processing_time double,

Keybase proof

I hereby claim:

  • I am duckworth on github.
  • I am duckworth (https://keybase.io/duckworth) on keybase.
  • I have a public key ASAl1ZkFc8u5PhInGF94hKwe8rj1z6k7kgnoqV1mlrOj0go

To claim this, I am signing this object:

# Ubuntu 14.04 LTS kickstart for XenServer
# branch: develop
##########################################
# Install, not upgrade
install
# Install from a friendly mirror and add updates
url --url http://us.archive.ubuntu.com/ubuntu/
#!/usr/bin/env ruby
require 'rubygems'
require 'net/ssh'
#need to install gem 'parallel'
require 'parallel'
#Path to file with hosts in it, one per line
HOSTFILE = "hosts.txt"
USER = 'root'
#ssh key path
KEYS = [ "~/.ssh/key" ]
@duckworth
duckworth / settings.xml
Created January 4, 2012 19:22
maven settings
<?xml version="1.0" encoding="UTF-8"?>
<settings xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd" xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<profiles>
<!--
This settings.xml file is a sample settings.xml that can be used to
retrieve Odiago (Wibi) artifacts as well as Hadoop, HBase, etc.
artifacts from Cloudera.
@duckworth
duckworth / update_bundles.rb
Last active September 25, 2015 03:57
my vim plugins/bundles
#!/usr/bin/env ruby
git_bundles = [
#"git://github.com/astashov/vim-ruby-debugger.git",
"git://github.com/msanders/snipmate.vim.git",
#"git://github.com/scrooloose/nerdtree.git",
#use wycats modified janus nerdtree
"git://github.com/wycats/nerdtree.git",
"git://github.com/timcharper/textile.vim.git",
"git://github.com/tpope/vim-cucumber.git",