Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
jczaplew committed Mar 1, 2016
0 parents commit 9f99ed1
Show file tree
Hide file tree
Showing 8 changed files with 58 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.DS_Store

credentials
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# GeoDeepDive Application Template


## Getting started
Dependencies:
+ [GNU Make](https://www.gnu.org/software/make/)
+ [git](https://git-scm.com/)
+ [pip](https://pypi.python.org/pypi/pip)
+ [PostgreSQL](http://www.postgresql.org/)

````
git clone https://github.com/UW-DeepDiveInfrastructure/app-template
cd app-template
make
````

Edit `credentials` with the connection credentials for your local Postgres database.
17 changes: 17 additions & 0 deletions config
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# The name of the application
app_name: Stringed instruments

# First and last name of the user
user: Example User

# The NLP product to run the application against
product: NLP352

# How often the application should be run
frequency: weekly

# A list of terms used to subset the corpus
terms: [banjo, guitar, violin, viola, piano, cello]

# Alternatively, a list of dictionaries can be provided in place of a list of terms
dictionaries: [instruments]
6 changes: 6 additions & 0 deletions credentials.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
postgres:
user: postgres_username
port: 5432
host: localhost
database: deepdive_app
password: password123
3 changes: 3 additions & 0 deletions makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
all:
cp credentials.example credentials;
pip install -r requirements.txt;
2 changes: 2 additions & 0 deletions output/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*
!.gitignore
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
psycopg2>=2.6.1
9 changes: 9 additions & 0 deletions run.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import yaml
import psycopg2
from psycopg2.extensions import AsIs

with open('./credentials', 'r') as credential_yaml:
credentials = yaml.load(credential_yaml)

with open('./config', 'r') as config_yaml:
config = yaml.load(config_yaml)

0 comments on commit 9f99ed1

Please sign in to comment.