Add web client and containerized deployment stack
All checks were successful
CI / test (push) Successful in 19s

Web client:

- Added React + TypeScript + Vite + Tailwind application in web/.

- Implemented auth, chat list, chat messages, typing indicators, file uploads, and voice recording/playback.

- Added typed API layer, Zustand stores, and realtime websocket hook integration.

Containerization:

- Added backend Dockerfile and project .dockerignore.

- Added web multi-stage Dockerfile with nginx static hosting and API/WS reverse proxy.

- Added full docker-compose stack with postgres, redis, minio, backend, worker, mailpit, and web.

- Added MinIO bucket bootstrap init job and updated README with Docker quick-start.
This commit is contained in:
2026-03-07 21:55:50 +03:00
parent 85631b566a
commit 2501466c7a
35 changed files with 4074 additions and 0 deletions

21
web/src/api/auth.ts Normal file
View File

@@ -0,0 +1,21 @@
import { http } from "./http";
import type { AuthUser, TokenPair } from "../chat/types";
export async function registerRequest(email: string, username: string, password: string): Promise<void> {
await http.post("/auth/register", { email, username, password });
}
export async function loginRequest(email: string, password: string): Promise<TokenPair> {
const { data } = await http.post<TokenPair>("/auth/login", { email, password });
return data;
}
export async function refreshRequest(refreshToken: string): Promise<TokenPair> {
const { data } = await http.post<TokenPair>("/auth/refresh", { refresh_token: refreshToken });
return data;
}
export async function meRequest(): Promise<AuthUser> {
const { data } = await http.get<AuthUser>("/auth/me");
return data;
}