Skip to content

jackwolfey/fast-user-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fast-user-manager

a basic but useful user management service with fastapi

Run Service

clone this repo first and then

pip install -r requirements.txt
python fast_user_manager.py --host localhost --port 8090 --workers 8

Use Api

import requests

r = requests.post('http://localhost:8090/register',
                  json={'username': 'john_smith', 'password': 'abcABC!0123'})
print(r.text)

# {"code":0,"msg":"success"}

After you first run, there will be two files generated at dir

db_secret.key is the secret key to encrypt and decrypt the database

user_data.pdb stores all user date, it's the database file

For more example, please refer test_api.py

Use control panel webui

export ADMIN_USERNAME=admin
export ADMIN_PASSWORD=admin_pw
python fast_user_manager.py --host localhost --port 8090 --workers 8

After this, open http://localhost:8090/control_panel in web browser

About

a basic but useful user management service with fastapi

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages