View safari-style-password.sh
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 | |
# ################################################ | |
# | |
# Generate a Safari-style password: V4R-cG2-Cru-J5d | |
# | |
# Usage: | |
# $ MY_PASSWORD=$(./safari-style-password.sh) | |
# $ echo $MY_PASSWORD | |
# |
View _returning.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
const { DB } = require('db') | |
const db = new DB() | |
// | |
;(async () => { | |
await db.connect() | |
await db.transaction(async (trx) => { | |
const user = await db.models.User.query(trx) | |
.insert({}) | |
.returning('*') |
View _no_returning.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
const { DB } = require('db') | |
const db = new DB() | |
// | |
;(async () => { | |
await db.connect() | |
await db.transaction(async (trx) => { | |
const user = await db.models.User.query(trx) | |
.insert({}) | |
console.log({ user }) |
View tinyWatcher.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
/** | |
* Uses fs.watchFile and cluster to watch, fork, and "restart" | |
* the file that this code is included in. Run this code before | |
* anything else in the script and it will restart a persistent- | |
* running fork of itself when the source is modified. | |
*/ | |
const fs = require('fs') | |
const cluster = require('cluster') |
View first_run.ini
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
# Modified from https://gist.github.com/HighMacGuy/3cf42ce21d3bd923f2440f9938e2f664 | |
cert-name = yourdomain.com | |
rsa-key-size = 4096 | |
email = webmaster@getethos.com | |
domains = vpn.ethoslife.com | |
agree-tos = True | |
# Would need to automate the process of adding a | |
# TXT record in Route53 for this to be automated: |
View businessLogic.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
const Redis = require('ioredis') | |
const services = require('./services') | |
const redis = new Redis() | |
;(() => { | |
const oneInstance = new services.One() | |
const one = oneInstance.getNumberOne() |
View keybase.md
Keybase proof
I hereby claim:
- I am heisian on github.
- I am ethos_tim (https://keybase.io/ethos_tim) on keybase.
- I have a public key ASAnDTs_vp7GA2feMPqzCVM-nyYUlh8a9tUip4gzBl6wZAo
To claim this, I am signing this object:
View Dockerfile-atlantis-ecs-git-crypt
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
# This Dockerfile is intended to be uploaded to a PRIVATE repository. | |
# This method involves copying the git-crypt key into this image, | |
# which will allow one to use a custom workflow in Atlantis | |
# to decrypt before running init/plan/apply. | |
FROM runatlantis/atlantis | |
ENV GIT_CRYPT_VERSION 0.6.0 | |
RUN apk --update add \ |
View exercise.md
Fullstack Exercise (Tim)
Create a Node server/client app that communicates via socket.io
.
Server/Client interaction
Connection
The server should listen for socket.io
connections and let any clients
know, on connection, that they've successfully connected. The server should
emit a success message to the client through the socket.io
channel.
OlderNewer