Skip to content

Commit 095154d

Browse files
committed
feat: config page in web
1 parent 9cd61e4 commit 095154d

File tree

12 files changed

+720
-264
lines changed

12 files changed

+720
-264
lines changed

Cargo.lock

Lines changed: 18 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,15 @@ serde_yaml = "0.9"
1111
sqlx = { version = "0.8.2", features = ["runtime-tokio", "sqlite", "time", "chrono"] }
1212
uuid = { version = "1.0", features = ["v4"] }
1313
axum = "0.8.1"
14-
tower-http = { version = "0.6.2", features = ["cors"] }
14+
tower-http = { version = "0.6.2", features = ["cors", "fs"] }
1515
chrono = { version = "0.4", features = ["serde"] }
1616
once_cell = "1.20.2"
1717
rust-embed = { version = "8.0", features = ["include-exclude"] }
1818
openssl = { version = "0.10", optional = true, features = ["vendored"] }
1919
dotenv = "0.15.0"
2020
env_logger = "0.11.6"
2121
log = "0.4.22"
22+
mime_guess = "2.0.5"
2223

2324
[dev-dependencies]
2425
tempfile = "3.9"

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,14 @@ database:
7272
### Environment Variables
7373
```bash
7474
DATABASE_URL=sqlite:data/bot.db # SQLite connection string
75+
CONFIG_PATH=data/config.yaml # Config file path
7576
```
7677

78+
## 🚨 Caution
79+
80+
- The config file is in plain text, so please do not share it with others.
81+
- The config page is accessible by anyone by default, so please set up a proper authentication method.
82+
7783
## 🤝 Contributing
7884

7985
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

src/http_server.rs

Lines changed: 0 additions & 262 deletions
This file was deleted.

0 commit comments

Comments
 (0)