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 React, { useState, useEffect, createContext, useContext, ReactNode } from 'react' | |
import Amplify, { Auth, Hub } from 'aws-amplify' | |
import { CognitoUser } from '@aws-amplify/auth' | |
import { CognitoUserSession } from 'amazon-cognito-identity-js' | |
import { HubCallback } from '@aws-amplify/core/lib/Hub' | |
import IUser from '../../types/IUser' | |
interface IAuthContext { | |
user: IUser | null | |
login(username: string, password: string): Promise<CognitoUser> |
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 MIT License (MIT) | |
Copyright (c) 2018 Abel Vázquez Montoro | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: |
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
'use strict' | |
import React, { Component } from 'react' | |
import PropTypes from 'prop-types' | |
import { Table, Menu, Icon, Segment, Input } from 'semantic-ui-react' | |
import capitalize from 'lodash/capitalize' | |
import flatten from 'lodash/flatten' | |
import orderBy from 'lodash/orderBy' | |
import debounce from 'lodash/debounce' |
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
gdal_translate image.tif image.mbtiles -of MBTILES | |
gdaladdo image.mbtiles 2 4 8 |
Examples of getting certificates from Let's Encrypt working on Apache, NGINX and Node.js servers.
I chose to use the manual method, you have to make a file available to verify you own the domain. Follow the commands from running
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt
-
createdb with postgres > create postgis/pgrouting extension > load road data with ogr2ogr or shp2pgsql or SPIT in QGIS
-
create vertices_tmp table with id/geom columns
select pgr_createTopology('roads', 0.5, 'geom', 'id');
- from 29788 = to the nearest 'vertices_tmp' node id to Station 15, select #all nodes less than 10 units (minutes) of cost
SELECT id, id1 AS node, id2 AS edge, cost, the_geom
INTO "20_10min_nodes"
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
################### | |
# compiled source # | |
################### | |
*.com | |
*.class | |
*.dll | |
*.exe | |
*.pdb | |
*.dll.config | |
*.cache |