https://github.com/M3ikShizuka/service-account
OAuth2 Ory Hydra Golang Identity Provider. Account management microservice. Clean Architecture. SOLID principles. Unit Test. Table Driven tests. Mock. Mock.
https://github.com/M3ikShizuka/service-account
account clean-architecture database databases golang gomock gorm gorm-orm identityprovider microservice mock oauth2 ory-hydra postgresql service solid unit-test viper zap
Last synced: 2 months ago
JSON representation
OAuth2 Ory Hydra Golang Identity Provider. Account management microservice. Clean Architecture. SOLID principles. Unit Test. Table Driven tests. Mock. Mock.
- Host: GitHub
- URL: https://github.com/M3ikShizuka/service-account
- Owner: M3ikShizuka
- Created: 2022-07-16T10:51:26.000Z (almost 3 years ago)
- Default Branch: develop
- Last Pushed: 2023-01-14T20:51:34.000Z (over 2 years ago)
- Last Synced: 2023-09-14T07:57:09.767Z (over 1 year ago)
- Topics: account, clean-architecture, database, databases, golang, gomock, gorm, gorm-orm, identityprovider, microservice, mock, oauth2, ory-hydra, postgresql, service, solid, unit-test, viper, zap
- Language: Go
- Homepage:
- Size: 9.6 MB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.MD
Awesome Lists containing this project
- awesome-ory - Ory Hydra Golang identity provider example
- awesome-ory - Ory Hydra Golang identity provider example
README
# Service Account
User's account management service.## Deployment
Deploy to Kubernetes with [k8s-microservices](https://github.com/M3ikShizuka/k8s-microservices).## Configurations
Change params in [configs/config.yml](https://github.com/M3ikShizuka/service-account/blob/develop/configs/config.yml) file if necessary to run the service locally (usually for develop and debug).
Use environment variables to set parameters when you deploy the service in a kubernetes cluster.## Unit tests
```bash
make test-unit
```## Generate Swagger API (OpenAPI) from code
Install swag
```bash
make swagger-install
```Generate API
```bash
make swagger-generate-api-doc
```Open site: `yourdomain`/swagger/index.html
## Libs
* [Argon2id](https://pkg.go.dev/golang.org/x/crypto/argon2) - user account password hash algorithm for store in database.
* [gorm](https://gorm.io) - ORM library.
* [viper](https://github.com/spf13/viper) - configuration.
* [zap](https://github.com/uber-go/zap) - logging.
* [gomock](https://github.com/golang/mock) - mocking framework.
* [go-sqlmock](https://github.com/DATA-DOG/go-sqlmock) - Sql mock driver for golang to test database interactions.
* [swag](https://github.com/swaggo/swag) - Automatically generate RESTful API documentation with Swagger 2.0 for Go.