| 1 |
# MakeNotWork |
| 2 |
|
| 3 |
Creator platform with 0% platform fee. Only Stripe's ~3% processing fee applies. Live at [makenot.work](https://makenot.work). |
| 4 |
|
| 5 |
## Monorepo Structure |
| 6 |
|
| 7 |
``` |
| 8 |
MNW/ |
| 9 |
server/ MNW server (Rust/Axum, PostgreSQL, HTMX) |
| 10 |
multithreaded/ Forum software (Rust/Axum, MNW OAuth integration) |
| 11 |
pom/ Production operations monitor (health checks, alerts) |
| 12 |
mnw-cli/ CLI tool for MNW platform |
| 13 |
shared/ Shared libraries |
| 14 |
docengine/ Markdown rendering + documentation engine |
| 15 |
tagtree/ Hierarchical tag standard |
| 16 |
synckit-client/ SyncKit cloud sync client SDK |
| 17 |
theme-common/ Theme loading + parsing (TOML themes) |
| 18 |
s3-storage/ S3-compatible storage abstraction |
| 19 |
themes/ TOML theme definitions (24 themes) |
| 20 |
tauri-updater-ui/ OTA update UI components |
| 21 |
``` |
| 22 |
|
| 23 |
## MNW Server |
| 24 |
|
| 25 |
Built with Rust (2024 edition), Axum, PostgreSQL, Askama templates, and HTMX. |
| 26 |
|
| 27 |
### Prerequisites |
| 28 |
|
| 29 |
- **Rust** (stable toolchain, 1.85+, 2024 edition) |
| 30 |
- **PostgreSQL** (16+) |
| 31 |
- **Environment variables** via `.env` file: database URL, Stripe keys, Postmark token, S3 credentials, Sentry DSN, session secret, JWT secret. See `server/.env.example` for the full list. |
| 32 |
|
| 33 |
### Build and Run |
| 34 |
|
| 35 |
All commands run from the `MNW/server/` directory: |
| 36 |
|
| 37 |
```sh |
| 38 |
# Development |
| 39 |
cargo run |
| 40 |
|
| 41 |
# Run unit tests (no database needed) |
| 42 |
cargo test |
| 43 |
|
| 44 |
# Run integration tests (needs a running PostgreSQL instance) |
| 45 |
TEST_DATABASE_URL="postgres://user:pass@host:5432/postgres" cargo test --test integration |
| 46 |
|
| 47 |
# Admin CLI |
| 48 |
cargo run --bin mnw-admin |
| 49 |
``` |
| 50 |
|
| 51 |
Production deployment uses `cargo zigbuild` for cross-compilation to x86_64 Linux. See `server/deploy/deploy.sh`. |
| 52 |
|
| 53 |
### Key Integrations |
| 54 |
|
| 55 |
- **Stripe Connect** -- creator payouts, subscriptions, checkout |
| 56 |
- **Postmark** -- transactional email (verification, password reset, purchase receipts) |
| 57 |
- **S3** (Hetzner Object Storage) -- file storage for creator uploads |
| 58 |
- **SyncKit** -- cloud sync and device management API for client applications |
| 59 |
- **Sentry** -- error tracking |
| 60 |
- **git2** -- built-in git source browser |
| 61 |
|
| 62 |
### Deployment |
| 63 |
|
| 64 |
Runs on a Hetzner VPS with systemd and Caddy (reverse proxy + TLS). No Docker. |
| 65 |
|
| 66 |
```sh |
| 67 |
cd server/ |
| 68 |
|
| 69 |
# Full deploy (cross-compile + upload + restart) |
| 70 |
./deploy/deploy.sh |
| 71 |
|
| 72 |
# Binary-only deploy (skip config files) |
| 73 |
./deploy/deploy.sh --quick |
| 74 |
|
| 75 |
# Config-only deploy (Caddyfile, systemd unit, static assets, error pages) |
| 76 |
./deploy/deploy.sh --config |
| 77 |
``` |
| 78 |
|
| 79 |
### Testing |
| 80 |
|
| 81 |
Each integration test creates and drops its own PostgreSQL database, so tests run in full isolation. Unit tests have no external dependencies. |
| 82 |
|
| 83 |
```sh |
| 84 |
cd server/ |
| 85 |
cargo test # Unit tests |
| 86 |
cargo test --test integration # Integration tests (needs TEST_DATABASE_URL) |
| 87 |
``` |
| 88 |
|
| 89 |
## License |
| 90 |
|
| 91 |
PolyForm Noncommercial 1.0.0 |
| 92 |
|