Skip to content

Instantly share code, notes, and snippets.

View JJediny's full-sized avatar

John Jediny JJediny

View GitHub Profile
@JJediny
JJediny / app.js
Last active August 29, 2015 14:20 — forked from pankaj28843/app.js
'use strict';
angular.module('App', ['ng', 'ngCookies', 'ngResource']);
angular.module('App').run(function($rootScope, $http, $cookies) {
$http.defaults.headers.common['X-CSRFToken'] = $cookies.csrftoken;
});
@JJediny
JJediny / local_settings.py
Last active August 29, 2015 14:25
local_settings.py for enabling python-social-auth in Geonode
"""
Only reflects the additional settings needed within local_settings.py file
"""
#INSTALLED_APPS = (
#python-social-auth
'social.apps.django_app.default',
#TEMPLATE_CONTEXT_PROCESSORS = (
# Python Social Auth
@JJediny
JJediny / Other_Public_Lands_FindYourPark.json
Created September 3, 2015 03:58
Copy of Request/Response from enabling "Other Public Lands" from http://findyourpark.com/find
{"result":true,"length":1862,"items":[{"park_id":"1431605944001974900","park_code":"other-143160594","park_type":"other","title":"1759 Vought House","state":"NJ","latitude":"40.64332300","longitude":"-74.89628300","type":"national_park","url":"http:\/\/www.nps.gov\/other-143160594\/index.htm"},{"park_id":"3hzg910O40yYICyEakmmmi","park_code":null,"park_type":"National Heritage Area","title":"Abraham Lincoln","state":"IL","latitude":"39.80028500","longitude":"-89.64814100","type":"national_park","url":null},{"park_id":"ZPAa5HFTQ2W2oEOycsosq","park_code":"ABLI","park_type":"National Historical Park","title":"Abraham Lincoln Birthplace","state":"KY","latitude":"37.53310000","longitude":"-85.73230000","type":"national_park","url":"http:\/\/www.nps.gov\/ABLI\/index.htm"},{"park_id":"3eJJn6wFPOCAIsk2sucy46","park_code":"ACAD","park_type":"National Park","title":"Acadia","state":"ME","latitude":"44.37630000","longitude":"-68.25840000","type":"national_park","url":"http:\/\/www.nps.gov\/ACAD\/index.htm"},{"park_id":"1
@JJediny
JJediny / docker_geonode
Last active September 9, 2015 15:24 — forked from ict4eo/docker_geonode
Docker install script for GeoServer/GeoNode
# GeoNode / GeoServer install for Docker
# Save file as Dockerbuild; sudo docker build -t ubuntu/testgeo3 .
# VERSION 1.0.0
FROM ubuntu
MAINTAINER Derek Hohls <[email protected]>
# make sure the package repository is up to date
RUN echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list
RUN apt-get update
@JJediny
JJediny / Ubuntu_CMD_toManuallyMapPorts
Created September 15, 2015 06:08
Manually Map Port 80 to 3000+
Port 80
What I do on my cloud instances is I redirect port 80 to port 3000 with this command:
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 3000
Then I launch my Node.js on port 3000. Requests to port 80 will get mapped to port 3000.
You should also edit your /etc/rc.local file and add that line minus the sudo. That will add the redirect when the machine boots up. You don't need sudo in /etc/rc.local because the commands there are run as root when the system boots.
@JJediny
JJediny / gist:a466eed62cee30ad45e2
Created October 5, 2015 20:42
Jekyll Liquid Cheatsheet

There are two types of markup in Liquid: Output and Tag.

  • Output markup (which may resolve to text) is surrounded by
{{ matched pairs of curly brackets (ie, braces) }}
  • Tag markup (which cannot resolve to text) is surrounded by
@JJediny
JJediny / data
Created October 19, 2015 00:40
Example of the `data` json configuration used by Geonode to Save Maps - http://nepanode.anl.gov/maps/812/view
{
"defaultSourceType": "gxp_wmscsource",
"about": {
"abstract": "",
"title": "Protected Areas of the United States"
},
"map": {
"layers": [
{
"opacity": 1,
@JJediny
JJediny / OpenSourceCheckList.md
Created October 28, 2015 05:35
Open Source Check List

Open Source Check List

Prior to releasing a project to GitHub.com, walk through these items and ensure they are addressed.

  • Has PII been removed?

    • Use Clouseau for scanning source code.
      • For an Open Source Release, attach the Clouseau output.
    • If there are images, visually inspect each image to ensure there is no CFPB-specific information.
  • Have security vulnerabilities been remediated?

@JJediny
JJediny / Geo.md
Last active November 13, 2015 17:48
Geospatial Libraries and Resources
@JJediny
JJediny / 12factorapp_checklist.md
Last active September 26, 2018 00:18
DRAFT checklist for developing or benchmarking an application against 12factor.net

The twelve-factor app Checklist

Also factors in the four principles of modern Release Engineering

  • Identifiability Being able to identify all of the source, tools, environment, and other components that make up a particular release.
  • Reproducibility The ability to integrate source, third party components, data, and deployment externals of a software system in order to guarantee operational stability.
  • Consistency The mission to provide a stable framework for development, deployment, audit, and accountability for software components.
  • Agility The ongoing research into what are the repercussions of modern software engineering practices on the productivity in the software cycle, i.e. continuous integration.