-
Add local domain to
/etc/hosts
:127.0.0.1 my-project.dev
-
Install mkcert
-
Create certificate for this domain:
➜ mkcert my-project.dev
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
// Rx HTTP Server | |
// first attempt at creating a minimal reactive nodejs HTTP server | |
// | |
// has: | |
// * url/querystring parsing | |
// * body parsing | |
// * some kind of routing | |
// * some kind of error handling | |
// * minimalist request logging | |
// |
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
{ | |
"swagger": "2.0", | |
"info": { | |
"title": "Passkit Web Service", | |
"contact": { | |
"name": "Clemens Krack", | |
"email": "info@clemenskrack.com" | |
}, | |
"version": "1.0.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
function *fibonacci(n) { | |
const infinite = !n && n !== 0; | |
let current = 0; | |
let next = 1; | |
while (infinite || n--) { | |
yield current; | |
[current, next] = [next, current + next]; | |
} | |
} |
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
{ | |
"type": "object", | |
"required": ["Statement"], | |
"additionalProperties": false, | |
"properties": { | |
"Version": { | |
"type": "string", | |
"enum": ["2008-10-17", "2012-10-17"] | |
}, | |
"Id": { |
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 type { Handler } from "aws-lambda"; | |
import { Pool } from "pg"; | |
// connection details inherited from environment | |
const pool = new Pool({ | |
max: 1, | |
min: 0, | |
idleTimeoutMillis: 120000, | |
connectionTimeoutMillis: 10000 | |
}); |
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/bash | |
sudo yum install gcc -y | |
sudo yum install openssl-devel -y | |
sudo yum install zlib-devel -y | |
sudo yum install mlocate -y | |
sudo yum install autoconf -y | |
wget https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-9.1p1.tar.gz | |
tar zxvf openssh-9.1p1.tar.gz | |
cd openssh-9.1p1 | |
./configure --prefix=/usr |
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
""" | |
Reorder site-packages ahead of Extras and lib-dynload. | |
Two implementations: | |
1. puts site-packages ahead of stdlib (technically hazardous, | |
but not really an issue). | |
2. is more conservative, only demoting Extras below site-packages. | |
Add this to ~/Library/Python/2.7/lib/python/site-packages/sitecustomize.py | |
""" |
Method:
sudo yum update
sudo yum install curl-devel expat-devel gettext-devel openssl-devel perl-devel zlib-devel
sudo yum install asciidoc xmlto docbook2X
sudo yum install gcc autoconf
sudo ln -s /usr/bin/db2x_docbook2texi /usr/bin/docbook2x-texi
wget https://github.com/git/git/archive/v2.8.4.zip