Heroku : https://go-sample-login-register.herokuapp.com
- Login (v1/auth/login)
- Register (v1/auth/register)
- User Detail (v1/me)
Go Sample Login Register uses a number of open source projects to work properly:
Go Sample Login Register requires Go v1.18 to run.
Build and start the server.
cd go_sample_login_register
export DATABASE_URL=CHANGEME
export DB_LOG_MODE=true #true or false
export DB_SSL_MODE=require #require or disable
export JWT_KEY=CHANGEME
go build main.go
./main.go
Go Sample Login Register is currently extended with the following Dependency.
Dependency | URL |
---|---|
jwt-go | [github.com/dgrijalva/jwt-go/v4] |
validator | [github.com/go-playground/validator/v10] |
uuid | [github.com/google/uuid] |
mux | [github.com/gorilla/mux] |
schema | [github.com/gorilla/schema] |
gorm | [github.com/jinzhu/gorm] |
crypto | [golang.org/x/crypto] |
MIT