Skip to content

Instantly share code, notes, and snippets.

View nmcspadden's full-sized avatar

Nick McSpadden nmcspadden

View GitHub Profile

WWDC Food Guide 2015

All of these restaurants can be found on Yelp. Yelp is a San Francisco native, so San Franciscans have very enthusiastically reported all of their restaurant findings to the Internet so that you may get an idea what to expect. Yelp is a great resource for finding information about local businesses in SF.

All of the block distances are from Moscone Center West.

Breakfast in the area

Mo'z Cafe - 1 block away

@nmcspadden
nmcspadden / JSSUpdater.py
Created June 4, 2014 14:52
This is for historical purposes, and likely can be done better via the new JSS 9.x API
#!/usr/bin/python
import sys
import csv
import subprocess
try:
import xml.etree.cElementTree as ElementTree
except ImportError:
import xml.etree.ElementTree as ElementTree
sed '/host all all 127.0.0.1\/32 trust/a host all all 172.17.0.1\/16 trust' pg_hba.conf
@nmcspadden
nmcspadden / Log in script for ARD
Last active August 29, 2015 14:14
Send UNIX Command for ARD to log in a device
osascript <<EndOfMyScript
set logInUser to "username"
set logInPassword to "password"
tell application "System Events"
tell application process "loginwindow"
key code 53
delay 1
key code 125
delay 1
key code 36 using option down
<key>mcx_preference_settings</key>
<dict>
<key>InstallAppleSoftwareUpdates</key>
<true/>
<key>SoftwareRepoURL</key>
<string>https://munki2.domain.com/repo</string>
<key>SoftwareUpdateServerURL</key>
<string>http://repo.domain.com/content/catalogs/others/index-10.10-10.9-mountainlion-lion-snowleopard-leopard.merged-1_release.sucatalog</string>
<key>SoftwareRepoCACertificate</key>
<string>/Library/Managed Installs/certs/ca.pem</string>
class munki_ssl {
if $::operatingsystem != 'Darwin' {
fail('The munki_ssl module is only supported on Darwin/OS X')
}
file { ['/Library/Managed Installs', '/Library/Managed Installs/certs/' ]:
ensure => directory,
owner => 'root',
group => 'wheel',
}
user { 'puppet':
ensure => 'absent',
}
group { 'puppet':
ensure => 'absent',
}
if $::operatingsystem == 'Darwin' {
include munki_ssl
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Source</key>
<string>/Applications/Install OS X Yosemite.app</string>
<key>Output</key>
<string>InstallYosemitePuppetMunki.pkg</string>
<key>Packages</key>
<array>
FROM nginx
RUN mkdir -p /munki_repo
Run mkdir -p /etc/nginx/sites-enabled/
ADD nginx.conf /etc/nginx/nginx.conf
ADD munki-repo.conf /etc/nginx/sites-enabled/
VOLUME /munki_repo
EXPOSE 80
FROM nmcspadden/munki
RUN apt-get -yqq update
RUN apt-get -yqq install curl lsb-release
RUN curl -L https://getchef.com/chef/install.sh | bash -s -- -v 11.16.2 -P container
ADD client.rb /etc/chef/client.rb
ADD validation.pem /etc/chef/validation.pem