sudo apt-get install postgresql-9.3-postgis-2.1
sudo su postgres
bash <(curl -s https://gist.githubusercontent.com/dlo/1860599/raw/514276029c43e6e68a2e2164f2a77fd53354b8e9/create_template.sh)
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
/* The API controller | |
Exports 3 methods: | |
* post - Creates a new thread | |
* list - Returns a list of threads | |
* show - Displays a thread and its posts | |
*/ | |
var Thread = require('../models/thread.js'); | |
var Post = require('../models/post.js'); |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<!-- Http Client --> | |
<dependency> | |
<groupId>org.apache.httpcomponents</groupId> | |
<artifactId>httpclient</artifactId> |
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
Steps: | |
Set up EBS | |
21Created 1 TB EBS | |
Created 64 Bit Amazon Linux AMI 2012.09 M1 Medium 3.7 gb ram, 2 ECUs | |
Connect to ec2 instance via ssh | |
chmod 400 IFS-KeyPair.pem | |
ssh -v -i IFS-KeyPair.pem [email protected] | |
Note: Do not replace ec2-user with your user id. This is a AWS Amazon AMI requirement. |
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
################################### | |
## CartoDB 2.0 Install [Working] ## | |
## Tested on Ubuntu 12.04 ## | |
################################### | |
# Change password | |
passwd | |
adduser [username] | |
adduser [username] sudo |
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
from urllib2 import urlopen | |
from cStringIO import StringIO | |
import json | |
from pyproj import Proj | |
from shapely.geometry import Point | |
from geopandas import GeoSeries, GeoDataFrame | |
# http://www.nyc.gov/html/dcp/download/bytes/nybb_13a.zip | |
boros = GeoDataFrame.from_file('/nybb_13a/nybb.shp', vfs='zip://nybb_13a.zip') | |
url = 'http://citibikenyc.com/stations/json' |
sudo apt-get update
sudo apt-get install git
cd ~
git clone --recursive https://github.com/CartoDB/cartodb20.git
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
# --------------------------------------------------------------------------- | |
# | |
# Description: This file holds all my BASH configurations and aliases | |
# | |
# Sections: | |
# 1. Environment Configuration | |
# 2. Make Terminal Better (remapping defaults and adding functionality) | |
# 3. File and Folder Management | |
# 4. Searching | |
# 5. Process Management |
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
/** | |
* Service to manage geoJSON layering with Leaflet.js' angular directive, which only allows 1 set of geoJSON data. | |
* | |
* Assuming you have a leaflet directive with its 'geojson' attribute set to `geojson`, usage is as follows: | |
* var layers = new GeoJSONLayers(); | |
* | |
* layers.addLayer('myLayer', geoJSON, function(feature) { return { fillColor: '#00F' }; }); | |
* $scope.geojson = layers.get(); | |
* | |
* layers.removeLayer('myLayer'); |
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
sudo wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo | |
sudo sed -i s/\$releasever/6/g /etc/yum.repos.d/epel-apache-maven.repo | |
sudo yum install -y apache-maven | |
mvn --version |
OlderNewer