Skip to content

Devang47/auth-server-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Project auth-server-go

This is a simple auth server written in Go. It uses a Postgres database to store user information and JWT tokens for authentication.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Routes

  • / - Home @returns auth-server-go

  • /health - Get Health @returns OK

  • /auth/google - Google OAuth2 route, starts auth flow @returns {token, account}

  • /logout - Logout @redirects to /

  • /account - Get current user account from DB @returns Account{}

  • /secure/account/{id} - Get account from DB using accountId @returns Account{}

MakeFile

build the application

make build

run the application

make run

Create DB container

make docker-run

Shutdown DB container

make docker-down

live reload the application

make watch

run the test suite

make test

clean up binary from the last build

make clean

About

Simple authentication server in GO

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published