Skip to content

Instantly share code, notes, and snippets.

View Jlaird's full-sized avatar

Jeremy Laird Jlaird

  • Endeavor Business Media
  • Fort Atkinson
View GitHub Profile
@Jlaird
Jlaird / move_images.sh
Last active August 29, 2015 14:17
Image Conversion
#!/bin/bash
limit=5000
counter=0
while [ $counter -lt $limit ]; do
image=$(head -n 1 images.txt)
echo "$(tail -n +2 images.txt)" > images.txt
@Jlaird
Jlaird / gist:b9cd2e2409939e02c3a0
Last active August 29, 2015 14:17
Drupal 404
http://nfocusnashville.com/wp-content/uploads/2012/12/MATCHGAME.jpg
http://nfocusnashville.com/wp-content/uploads/2013/02/In-Champagne-at-Château-De-Fere.jpg
http://nfocusnashville.com/wp-content/uploads/2013/02/In-Champagne-at-Château-De-Fere-2.jpg
http://nfocusnashville.com/wp-content/uploads/2013/02/In-Champagne-at-Château-De-Fere-2.gif
http://nfocusnashville.com/wp-content/uploads/2013/02/In-Champagne-at-Château-De-Fere.gif
http://nfocusnashville.com/wp-content/uploads/2013/02/Dinner-in-Champagne-at-Château-De-Fere.gif
http://nfocusnashville.com/wp-content/uploads/2013/03/55.jpg
http://nfocusnashville.com/wp-content/uploads/2013/08/NSTYLE.jpg
http://nfocusnashville.com/wp-content/uploads/2013/10/NSTYLE.jpg
@Jlaird
Jlaird / gist:0811228b00e9681ffe4b
Last active August 29, 2015 14:20
Mongo Config
systemLog:
destination: file
path: "/var/log/mongo/mongod.log"
logAppend: true
quiet: true
operationProfiling:
mode: off
slowOpThresholdMs: 1000
@Jlaird
Jlaird / Live config
Last active July 6, 2016 19:44
Live config
systemLog:
destination: file
path: "/var/log/mongodb/mongod.log"
logAppend: true
quiet: true
operationProfiling:
mode: off
slowOpThresholdMs: 10000
@Jlaird
Jlaird / mongo.conf
Created August 15, 2016 15:18
Dev Mongo Config
systemLog:
destination: file
path: "/var/log/mongodb/mongod.log"
logAppend: true
quiet: true
operationProfiling:
mode: off
slowOpThresholdMs: 10000
@Jlaird
Jlaird / docker.sh
Created August 15, 2016 17:54
Dev docker setup
#!/bin/bash
# Create directories
mkdir -p ~/data/mongo/db
mkdir -p ~/data/mongo/configdb
mkdir -p ~/data/redis
mkdir -p ~/data/elastic
# Get Mongo conf
curl https://gist.githubusercontent.com/Jlaird/3907584bc6c52a748172d95948f6d496/raw/640a47ed277b54b416f7eec27e871970fb5e09fc/mongo.conf > ~/data/mongo/configdb/mongo.conf
2016-09-15T19:00:45-05:00
Server: Array
(
[REDIRECT_SCRIPT_URL] => /music/interviews/article/20833557/local.cltampa.com
[REDIRECT_SCRIPT_URI] => http://www.cltampa.com/music/interviews/article/20833557/local.cltampa.com
[REDIRECT_APP_ENV] => prod
[REDIRECT_USE_CACHE] => false
[REDIRECT_USE_APC] => false
[REDIRECT_HOSTNAME] => ip-10-0-1-14
@Jlaird
Jlaird / sola_export.sh
Last active October 31, 2016 16:14
Sola expoort
#!/usr/bin
#Sync Images to their S3 Bucket
aws s3 sync --exact-timestamps s3://media.cygnus.com/files/base/sola/ s3://solaserver
mongodump -h 10.0.2.50 -d sola_frpc_brevity
mongodump -h 10.0.2.50 -d sola_frpc_configuration
mongodump -h 10.0.2.50 -d sola_frpc_contracts
mongodump -h 10.0.2.50 -d sola_frpc_email
mongodump -h 10.0.2.50 -d sola_frpc_import
#!/bin/bash
echo $1
aws route53domains disable-domain-transfer-lock --domain-name $1
aws route53domains retrieve-domain-auth-code --domain-name $1
sleep 2
#!/bin/bash
#aws route53 create-hosted-zone --name altdotpop.com --caller-reference 2016-02-09-18:51 --hosted-zone-config Comment="Southcomm"
Id=$(aws route53 list-hosted-zones-by-name --dns-name baseplatform.io. --max-items 1 --query 'HostedZones[*].Id' --output text | awk -F'/hostedzone/' '{print $2}')
echo "