update docs
All checks were successful
Build and deploy / Build and Push Docker Images (push) Successful in 2m30s
All checks were successful
Build and deploy / Build and Push Docker Images (push) Successful in 2m30s
This commit is contained in:
83
README.md
83
README.md
@@ -1,8 +1,75 @@
|
||||
# ISP Wiremap Application
|
||||
|
||||
A web-based mapping application for managing ISP network infrastructure with real-time collaboration features.
|
||||
|
||||
## run migrations
|
||||
## Tech Stack
|
||||
|
||||
- **Backend:** FastAPI with Python 3, PostgreSQL 15 with PostGIS
|
||||
- **Frontend:** React 19 with TypeScript, Vite, Leaflet for mapping
|
||||
- **Authentication:** JWT tokens with bcrypt password hashing
|
||||
- **Real-time:** WebSockets for collaborative editing
|
||||
|
||||
## Getting Started
|
||||
|
||||
### Run Migrations
|
||||
|
||||
```bash
|
||||
docker compose exec python alembic upgrade head
|
||||
```
|
||||
|
||||
### Start the Application
|
||||
|
||||
```bash
|
||||
docker compose up -d
|
||||
```
|
||||
|
||||
The application will be available at `http://localhost:8000`
|
||||
|
||||
## User Management
|
||||
|
||||
### Create Admin User
|
||||
|
||||
Interactively create a new admin user with username, email, and password:
|
||||
|
||||
```bash
|
||||
docker compose exec python python scripts/create_admin.py
|
||||
```
|
||||
|
||||
### List Users
|
||||
|
||||
View all users in the system with their details (username, email, admin status, creation date):
|
||||
|
||||
```bash
|
||||
docker compose exec python python scripts/manage_users.py list
|
||||
```
|
||||
|
||||
### Reset User Password
|
||||
|
||||
Reset a user's password by providing their username, email, or user ID:
|
||||
|
||||
```bash
|
||||
docker compose exec python python scripts/manage_users.py reset-password <username|email|user_id>
|
||||
```
|
||||
|
||||
### Delete User
|
||||
|
||||
Delete a user from the system (requires confirmation, affects all their maps and shares):
|
||||
|
||||
```bash
|
||||
docker compose exec python python scripts/manage_users.py delete <username|email|user_id>
|
||||
```
|
||||
|
||||
### Toggle Admin Status
|
||||
|
||||
Grant or revoke admin privileges for a user:
|
||||
|
||||
```bash
|
||||
docker compose exec python python scripts/manage_users.py toggle-admin <username|email|user_id>
|
||||
```
|
||||
|
||||
## Production Deployment
|
||||
|
||||
Example Docker Compose configuration for production:
|
||||
|
||||
```yaml
|
||||
services:
|
||||
@@ -38,5 +105,17 @@ services:
|
||||
# ports:
|
||||
# - "5432:5432"
|
||||
```
|
||||
## prod docker compose.yml
|
||||
|
||||
## Environment Configuration
|
||||
|
||||
Copy `.env.example` to `.env` and configure the required variables:
|
||||
|
||||
- `SECRET_KEY` - JWT secret key for token signing
|
||||
- `DATABASE_URL` - PostgreSQL connection string
|
||||
- `ALLOW_REGISTRATION` - Enable/disable public user registration (default: false)
|
||||
- `ACCESS_TOKEN_EXPIRE_MINUTES` - JWT access token lifetime (default: 30)
|
||||
- `REFRESH_TOKEN_EXPIRE_DAYS` - JWT refresh token lifetime (default: 7)
|
||||
|
||||
## License
|
||||
|
||||
GPL v2
|
||||
|
||||
Reference in New Issue
Block a user