Skip to content

Instantly share code, notes, and snippets.

Avatar

Lee Boonstra savelee

View GitHub Profile
@savelee
savelee / gist:ee2cf546493551d1448a
Created Jul 1, 2015
Start Sencha Webserver from the command-line
View gist:ee2cf546493551d1448a
sencha fs web -p 80 start -map /path/to/webroot/
@savelee
savelee / gist:5724e99ed51e79cf22c7
Created Jul 8, 2015
Show all hidden files on Mac OSX
View gist:5724e99ed51e79cf22c7
defaults write com.apple.finder AppleShowAllFiles TRUE && killall Finder
@savelee
savelee / gist:85d56cd290f755752b66
Created Jul 9, 2015
Dokku add environment variable
View gist:85d56cd290f755752b66
dokku config:set appname KEY=value
@savelee
savelee / gist:662f58ebcee7889ade60
Last active Aug 29, 2015
Shutdown digital ocean ubuntu droplet
@savelee
savelee / gist:dc4d9917df453b068905
Created Jul 10, 2015
Restart Apache on Ubuntu
View gist:dc4d9917df453b068905
sudo service apache2 restart
@savelee
savelee / gist:6701c707b8f5805c9cf7
Created Jul 10, 2015
Setup php mail Ubuntu digital ocean
View gist:6701c707b8f5805c9cf7
//login to your droplet.
//1. output the hostname
hostname
//2. modify the hosts
nano /etc/host
//3. the first line in this file, should use the hostname on the end. For example: "Lee"
127.0.0.1 localhost localhost.domainname Lee
View gist:0e7023e53049bafd597d
https://www.digitalocean.com/community/tutorials/how-to-install-mongodb-on-ubuntu-14-04
//Check if mongo is running
service mongod status
//You can also stop, start, and restart MongoDB using the service command (e.g. service mongod stop, server mongod start).
View gist:304b861a1417f33fc669
yo nodejs
//install modules globally
npm install packagename -g
//install modules and save in package.json
npm install packagename --save
@savelee
savelee / gist:2be4dcadb7638b005365
Last active Aug 29, 2015
Unload & Reload discoveryd to Fix DNS & Wi-Fi Failures in OS X Yosemite
View gist:2be4dcadb7638b005365
This trick involves refreshing the discoveryd service by unloading and reloading it with the launchctl command.
This is a bit curious but apparently it works for some users, suggesting there could be an issue with discovery or resolving DNS on some Yosemite Macs.
It’s certainly worth a try if the above tricks failed to resolve your wi-fi connectivity problems in OS X 10.10, as there are a fair amount of positive reports with this one:
Open Terminal (found in /Applications/Utilities/ or with Spotlight) and enter the following command:
`sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.discoveryd.plist`
Hit return and enter an admin password to use the sudo command
Now run the following command to reload discoveryd (this used to be called mDNSResponder)
`sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.discoveryd.plist`
@savelee
savelee / gist:510e93bd6f499e6c66e5
Created Jul 29, 2015
Dokku listing containers
View gist:510e93bd6f499e6c66e5
Listing running containers: dokku ps
To kill a container:
dokku kill <id-container>
https://docs.docker.com/articles/basics/
You can’t perform that action at this time.