Skip to content

Latest commit

 

History

History
41 lines (38 loc) · 795 Bytes

README.md

File metadata and controls

41 lines (38 loc) · 795 Bytes

Projects

this application Architecture

  • golang
  • postgresql
  • k8s

Libraries

sqlc install

go install github.com/kyleconroy/sqlc/cmd/sqlc@latest

How to use

build up

# docker-compose up -d --build
make build

create database

# make database simple_bank
make createdb

migrations

# docker-compose exec migrate bash -c 'migrate -path ./migrate -database "{DATABASE_ENGINE}://{POSTGRES_USER}:{POSTGRES_PASSWORD}@db:{PORT}/{DATABASE_NAME}?sslmode=disable" -verbose up'
make migrate-up

sql-builder

# cd ./db && sqlc generate && cd -
make sqlc

test-coverage

make test