Skip to content
/ jwt Public

JWT authentication server with angular form frontend.

License

Notifications You must be signed in to change notification settings

cprepos/jwt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jwt

#LINUX JWT PROD SERVER INSTRUCTIONS

JWT authentication server using DynamoDB backend. API has a redis based rate limiter that only allows 100 requests per minute.

Frontend handled with Angular 1.5.8. Communication is done using a $resource factory.

Assumptions: -REDIS is installed on default port (Instructions: https://www.digitalocean.com/community/tutorials/how-to-install-and-use-redis) -JAVA is installed (for dynamoDB local) -If using non-GUI linux machine, Xvfb and xvfb-run are installed and working (for e2e tests to work) or another GUI emulator

Clone: "git clone https://github.com/cprepos/jwt/ jwt"

install PM2: (sudo) npm install -g pm2

Install: "cd jwt && npm install"

Test server (IMPORTANT, IF NON-GUI ONLY, USE xvfb-run OTHERWISE e2e TESTS WILL FAIL): if non-GUI Linux:"xvfb-run -a npm test" ; if GUI:"npm test". //This will concurrently start server/DynamoDB/tests. Not for production.

Production Environment "export NODE_ENV=production"

Start Dynamo Server as service (this must be running for everything to work obviously): "pm2 start DynamoLocalServer.js"

Start Production API server: "pm2 start server.js -i 4" //edit the 4 for the number of processor cores you want to use or have available

About

JWT authentication server with angular form frontend.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published