version: '3.5'
services:
postgres:
container_name: postgres_container
image: postgres
environment:
POSTGRES_USER: ${POSTGRES_USER:-postgres}
This file contains hidden or 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
export type Operations = | |
| 'aggregate' | |
| 'count' | |
| 'create' | |
| 'createMany' | |
| 'delete' | |
| 'deleteMany' | |
| 'findFirst' | |
| 'findMany' | |
| 'findUnique' |
This file contains hidden or 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
version: '3.5' | |
# docker with pgadmin/postgres/nodejs | |
# endable docker to start with OS | |
# - sudo systemctl enable docker | |
# to run: | |
# sudo docker-compose up -d | |
# remove the -d to get messages from docker, do not run in vscode | |
# todo add redis memory db for users etc | |
services: | |
postgres: |
This file contains hidden or 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 redisClient = redis.createClient(REDIS_URL); | |
const listeners = Object.create(null); | |
function addListener(channel, listener) { | |
if (!listeners[channel]) { | |
listeners[channel] = []; | |
redisClient.subscribe(channel); | |
} | |
listeners[channel].push(listener); |
Inspired and edited from this Digital Ocean tutorial.
Follow the steps on this gist to setup a LEMP stack with PHP 7.0.
The steps assume Nginx has been configured correctly.
For the domains example.com
and test.com
, create the folders.