diff --git a/README.md b/README.md index 4529894..11fca42 100644 --- a/README.md +++ b/README.md @@ -69,9 +69,6 @@ All on one page Diagram describes general architecture of the application. [Source PUML code](docs/architecture-overview.puml) ![architecture overview](https://plantuml.com/plantuml/svg/5Sqx3WCX30RXFgT83W0kaYhLNeKrLa3YWSplvVfXgz5NpJ4H55RBuvKR5ujYMfu96FDBf67vNqQoqwOezmPfyDmhJVGcRdt0wQrRCXm7j-IqJ3LiAyNEau9ooX26gRX-YLvPbX_ty90MT_y0) -### UI Mockup -See [docs/ui-mockups.md](docs/ui-mockups.md) for ASCII mockups of the UI. - ### Logging Convenient logging allows system to be transparent about underlying CLI wrapping. This is important due to unstable nature of CLI tools. @@ -97,38 +94,38 @@ project_root/ │ ├── docker-compose.yml ├── README.md -│ -├── docs/ -│ ├── class-diagram.puml -│ ├── core-api.yaml -│ ├── architecture-overview.puml -│ └── ui-mockups.md -├── shared/ -│ ├── __init__.py -│ ├── cli_wrapper.py -│ ├── logger.py -│ └── models.py -│ -├── web_frontend/ -│ ├── Dockerfile -│ ├── requirements.txt -│ ├── app.py -│ ├── api_client.py -│ ├── ui_components.py -│ └── templates/ -│ ├── base.html -│ ├── dashboard.html -│ ├── logs.html -│ ├── certificate_management.html -│ └── modals/ -│ └── generate_cert.html +├── requirements.txt │ ├── core/ -│ ├── Dockerfile -│ ├── requirements.txt -│ ├── main.py │ ├── api_server.py -│ └── certificate_manager.py +│ ├── certificate_manager.py +│ ├── Dockerfile +│ ├── main.py +│ └── requirements.txt +│ +├── docs/ +│ ├── architecture-overview.paml +│ ├── class-diagram.puml +│ └── core-api.yaml +│ +├── front/ +│ ├── api_client.py +│ ├── Dockerfile +│ ├── main.py +│ ├── requirements.txt +│ └── html/ +│ ├── dashboard.html.j2 +│ ├── logs.html.j2 +│ ├── styles.css +│ └── script.js +│ +├── shared/ +│ ├── __init__.py +│ ├── api_models.py +│ ├── cli_wrapper.py +│ ├── db_logger.py +│ ├── logger.py +│ └── models.py │ ├── auto_setup/ │ ├── auto_setup.py diff --git a/docs/ui-mockups.md b/docs/ui-mockups.md deleted file mode 100644 index 9619466..0000000 --- a/docs/ui-mockups.md +++ /dev/null @@ -1,81 +0,0 @@ -# ASCII Mockups - -Main page: -``` -+--------------------------------------------+ -| Logo [Dashboard] [Logs] [Menu] | -+--------------------------------------------+ -| | -| Certificate Management | -| +--------------------------------------+ | -| | List of Certificates | | -| | +--------------------------------+ | | -| | | Cert Name | Status | Actions | | | -| | |-----------|---------|----------| | | -| | | Cert 1 | Active | [Renew] | | | -| | | | | [Revoke] | | | -| | |-----------|---------|----------| | | -| | | Cert 2 | Expired | [Delete] | | | -| | +--------------------------------+ | | -| | | | -| | [Generate New Certificate] | | -| +--------------------------------------+ | -+--------------------------------------------+ -``` - -Generate cert modal dialog: -``` -+------------------------------------------+ -| Generate New certificate | -| +------------------------------------+ | -| | Key Name: __ | | -| | Key Type: >RSA | | #dropdown: RSA etc -| | Duration: ___ >days | | #dropdown: minutes, hours etc -| | | | -| | Command that will be executed: | | -| | [Click here to reload preview] | | -| | [Execute!] | | # if preview is loaded and all fields are filled -| | <$ step-ca command ... > | | -| | | | -| | Logs: | | -| | | | -| +------------------------------------+ | -+------------------------------------------+ -``` - -Logs page: -``` -+-----------------------------------------------------------------+ -| Logo [Dashboard] [Logs] [Menu] | -+-----------------------------------------------------------------+ -| | -| Logs and Command History | -| +-----------------------------------------------------------+ | -| | Filters: | | -| | Severity: [All v] Type: [All v] | | -| | Date Range: [From] [To] [Apply] | | -| | | | -| | Search: [____________] [Search] | | -| | | | -| | +-------------------------------------------------------+ | | -| | | EntryID | Timestamp | Severity | TraceID | Message | | | -| | |---------|-----------|----------|---------|------------| | | -| | | 00002 | 2023-08-1 | INFO | abc123 | Generating | | | -| | | | 7 10:15 | | | new cert | | | -| | | | $ step ca certificate ... | | | -| | | | [Click to see command output...] | | | -| | |---------|---------------------------------------------| | | -| | | 00003 | 2023-08-1 | WARN | def456 | Cert not | | | -| | | | 7 10:14 | | | exists | | | -| | |---------|--------------------------------|------------| | | -| | | 00004 | 2023-08-1 | DEBUG | def456 | Request | | | -| | | | 7 10:13 | | | revoke | | | -| | |---------|--------------------------------|------------| | | -| | | 00005 | 2023-08-1 | ERROR | ghi789 | Permission | | | -| | | | 7 10:12 | | | denied | | | -| | +-------------------------------------------------------+ | | -| | | | -| | [Load More] | | -| +-----------------------------------------------------------+ | -+-----------------------------------------------------------------+ -``` diff --git a/front/main.html b/front/html/dashboard.html similarity index 100% rename from front/main.html rename to front/html/dashboard.html diff --git a/front/logs.html b/front/html/logs.html similarity index 100% rename from front/logs.html rename to front/html/logs.html diff --git a/front/script.js b/front/html/script.js similarity index 100% rename from front/script.js rename to front/html/script.js diff --git a/front/styles.css b/front/html/styles.css similarity index 100% rename from front/styles.css rename to front/html/styles.css diff --git a/requirements.txt b/requirements.txt index 6b0477f..284d9f8 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,4 @@ +# dev uvicorn~=0.30.6 fastapi~=0.112.1 pydantic~=2.8.2 diff --git a/shared/__init__.py b/shared/__init__.py new file mode 100644 index 0000000..e69de29