Simple local network client-server chatting web app with Spring Boot and Angular.
Note that this app is intended as a learning aid and personal reference. Unsafe for production due to custom authentication logic.
- Backend
- Spring Boot
- PostgreSQL (with Flyway migrations)
- Swagger codegen (openapi)
- WebSockets
- Unit tests (SpringBoot, MockK)
- Frontend
- Angular 16 ( + Material Design )
- NgRx store ( + router-store)
- Audio worklets + WebSockets (for basic voice transmission)
- Karma tests
- Deployment with Docker/Podman
- Build with gradle and run on openjdk:17-jdk-alpine image
- Dev and prod configurations for docker-compose.yaml
- User authentication
- Register/login/logout and view/delete active login cookies
- Conversation
- Users may create a new conversation and add/remove members
- Desktop notifications (informed by Server-sent events (SSE))
- Infinite scroll for older messages
- Edit member permissions (and color)
- Text/Regex search with message highlighting
- Experimental voice transmission (without WebRTC) via WebSockets + AudioWorklet
Generate a key store for the dev
profile:
./gen-keystore.sh dev
Run the backend api at localhost:9432
without assembling the webclient:
docker-compose up -d db pgadmin
POSTGRES_HOST=localhost ./gradlew server:bootRun -x :server:webclient:assembleFrontend
Then, run the webclient in development
configuration at localhost:4200
:
cd server/src/webclient && yarn install
yarn start
Generate a key store for the prod
profile:
./gen-keystore.sh prod
Then, configure docker-compose.prod.yaml
and startup an instance:
./gradlew build
docker-compose up -f docker-compose.yaml -f docker-compose.prod.yaml -d
Note that by default server.ssl.enabled: false
and some existing reverse proxy configuration is expected for SSL.