add handler, html templates, Makefile and migrations

This commit is contained in:
Philipp 2021-08-29 16:37:20 +02:00
commit a06e8db2ff
WARNING! Although there is a key with this ID in the database it does not verify this commit! This commit is SUSPICIOUS.
GPG key ID: 276B613AF9DBE9C3
22 changed files with 1001 additions and 0 deletions

18
Makefile Normal file
View file

@ -0,0 +1,18 @@
.PHONY: postgres adminer migrate
postgres:
docker run --rm -ti --network host -e POSTGRES_PASSWORD=secret postgres
adminer:
docker run --rm -ti --network host adminer
reflex:
reflex -s go run cmd/goddit/main.go
migrate:
migrate -source file://migrations \
-database postgres://postgres:secret@localhost/postgres?sslmode=disable up
migrate-down:
migrate -source file://migrations \
-database postgres://postgres:secret@localhost/postgres?sslmode=disable down