This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/ This is a basic configuration for the Kea DHCPv4 server. Subnet declarations | |
// are mostly commented out and no interfaces are listed. Therefore, the servers | |
// will not listen or respond to any queries. | |
// The basic configuration must be extended to specify interfaces on which | |
// the servers should listen. There are a number of example options defined. | |
// These probably don't make any sense in your network. Make sure you at least | |
// update the following, before running this example in your network: | |
// - change the network interface names | |
// - change the subnets to match your actual network | |
// - change the option values to match your network |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Plug in one interface | |
use ip addr to work out which interfaces there are and which is the WAN interface | |
Set up /etc/networks/interfaces | |
#loopback | |
auto lo | |
iface lo inet loopback |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
You'd probably want a domain name and such already setup. You'll also want oauth setup | |
in https://console.developers.google.com/project under credentials and elsewhere. | |
I'm doing this as a regular user with sudo permissions using ubuntu server 14.04lts. | |
install curl | |
nodesource repos for io.js | |
curl -sL https://deb.nodesource.com/setup_iojs_1.x | sudo bash - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
def searchTweets(query): | |
search = requests.get("http://search.twitter.com/search.json?q="+query) | |
dict = search.json() | |
for result in dict["results"]: # result is a list of dictionaries | |
print ("*",result["text"],"\n") | |
#inspired by on http://glowingpython.blogspot.de/2011/04/how-to-use-twitter-search-api.html, rewritten in python 3 and using requests by Ravi Mohan, The Journeyman Geek |