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
const rectangles = require('./buildings2.json').features | |
const points = require('./dmv_props.json').features | |
const bbox = require('@turf/bbox').default | |
const RBush = require('rbush') | |
function prepare(features) { | |
return features.map(f => { | |
const box = bbox(f) | |
return { | |
minX: box[0], |
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
const rectangles = require('./buildings2.json').features | |
const points = require('./dmv_props.json').features | |
const bbox = require('@turf/bbox').default | |
const RBush = require('rbush') | |
function prepare(features) { | |
return features.map(f => { | |
const box = bbox(f) | |
return { | |
minX: box[0], |
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
const fetch = require('node-fetch') | |
const generateToken = require('./lib/token').generate | |
module.exports = async function (args) { | |
const dcatUrl = `${args.site}/data.json` | |
const catalog = await fetch(dcatUrl).then(r => { return r.json() }) | |
const formatted = catalog.dataset.map(d => { | |
return { | |
title: d.title, |
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
{ | |
"__inputs": [ | |
{ | |
"name": "DS_NGINX-ACCESS-LOG", | |
"label": "nginx-access-log", | |
"description": "", | |
"type": "datasource", | |
"pluginId": "elasticsearch", | |
"pluginName": "Elasticsearch" | |
} |
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
#!/bin/sh | |
DIR=$(dirname"$0") | |
STAMP=$(date +%s) | |
TEMPDIR="/srv/hub/$STAMP" | |
APPLICATIONDIR="/arcgis/portal/apps/hub" | |
OLDDIR=$(cat ./.old-directory) | |
echo "downloading files to $DIR" | |
/usr/local/bin/aws s3 cp s3://REDACTED/build.tar.gz "$DIR" |
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
GET /:provider/:id | |
DELETE /:provider/:id | |
PUT /:provider/:id Content-Type: application/json | |
{ | |
name: | |
description: | |
schemas: { | |
georgia: { | |
}, |
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
{ | |
"name": "koop-trimet", | |
"version": "1.0.8", | |
"description": "A Trimet provider for koop", | |
"main": "index.js", | |
"directories": { | |
"test": "test" | |
}, | |
"scripts": { | |
"start": "node server.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
//clean shutdown | |
process.on('SIGINT', () => process.exit(0)) | |
process.on('SIGTERM', () => process.exit(0)) | |
// Initialize Koop | |
const Koop = require('koop') | |
const koop = new Koop() | |
// Install the Yelp Provider | |
const yelp = require('yelp') |
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
const express = require('express') | |
const app = express() | |
const Koop = new Koop() | |
app.use(koop.server) | |
app.listen(80) |
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
const Koop = require('koop') | |
const koop = new Koop() | |
koop.server.listen(80) |
NewerOlder