Import documentation: README.md

Import the existing local project snapshot. This commit organizes existing files; it does not represent newly developed functionality.
This commit is contained in:
arsam
2026-09-18 23:15:49 +03:30
parent 30a095ce41
commit 89020fb528
+41
View File
@@ -0,0 +1,41 @@
# CShare
CShare is a production-shaped file sharing app with a Vite/React frontend and a TypeScript/Express backend. It supports file upload, expiring share links, recipient previews for small safe files, downloads, dashboard stats, and an admin API.
## Project Layout
- `cshare-app/` - React frontend, Vite build, precompressed static assets.
- `backend/` - Express API, local disk storage adapter, JSON metadata store, auth primitives, admin API.
- `PRODUCTION.md` - deployment notes, required env, Nginx guidance.
- `deploy/` - sample service and reverse-proxy config.
## Local Development
Backend:
```sh
cd backend
npm install
npm run dev
```
Frontend:
```sh
cd cshare-app
npm install
VITE_API_BASE_URL=http://localhost:4001 npm run dev
```
## Final Checks
```sh
cd backend && npm run check
cd ../cshare-app && npm run check
```
Frontend builds create gzip and Brotli assets in `cshare-app/dist/`. Backend production startup requires strong `JWT_ACCESS_SECRET`, `JWT_REFRESH_SECRET`, and `ADMIN_API_KEY` values.
## Publish Notes
Before publishing, configure the environment in `PRODUCTION.md`, serve `cshare-app/dist/` with a static host or Nginx, and proxy `/api` plus `/health` to the backend. The included local JSON/disk persistence is suitable for a single-server launch; move to PostgreSQL/R2 before depending on durable multi-server storage.