Skip to content

Latest commit

 

History

History
70 lines (45 loc) · 1012 Bytes

README.md

File metadata and controls

70 lines (45 loc) · 1012 Bytes

Address Microservice

Prerequisites

Usage

Create configs/config.toml file. You can use configs/config.example.toml as example

Install dependencies:

make deps

Run server:

make run

Build binary:

make build

Development

Update SQLC schema (schema.sql) and queries (query.sql). Then generate Go code (models, interfaces etc):

 make sqlc_generate

Update protobuf spec (proto/address.proto) and then generate Go code:

 make proto_generate

GRPC procedures implementation is in internal/grpcserver/grpcserver.go

Tests

Run tests:

make test

Linter

Run linter:

make lint

Database migrations

cd ./migrations
goose postgres "user=<user name> password=<password> dbname=<dbname> sslmode=disable" up