All checks were successful
Queue Release Build / prepare (push) Successful in 21s
Deploy Web Apps / deploy (push) Successful in 15m14s
Queue Release Build / build-linux (push) Successful in 22m12s
Queue Release Build / build-windows (push) Successful in 23m20s
Queue Release Build / finalize (push) Successful in 2m12s
55 lines
1.8 KiB
Markdown
55 lines
1.8 KiB
Markdown
# Toju / Zoracord
|
|
|
|
Desktop chat app with three parts:
|
|
|
|
- `src/` Angular client
|
|
- `electron/` desktop shell, IPC, and local database
|
|
- `server/` directory server, join request API, and websocket events
|
|
|
|
## Install
|
|
|
|
1. Run `npm install`
|
|
2. Run `cd server && npm install`
|
|
3. Copy `.env.example` to `.env`
|
|
|
|
## Config
|
|
|
|
Root `.env`:
|
|
|
|
- `SSL=true` uses HTTPS for Angular, the server, and Electron dev mode
|
|
- `PORT=3001` changes the server port in local development and overrides the server app setting
|
|
|
|
If `SSL=true`, run `./generate-cert.sh` once.
|
|
|
|
Server files:
|
|
|
|
- `server/data/variables.json` holds `klipyApiKey`
|
|
- `server/data/variables.json` also holds `releaseManifestUrl` for desktop auto updates
|
|
- `server/data/variables.json` can now also hold optional `serverHost` (an IP address or hostname to bind to)
|
|
- `server/data/variables.json` can now also hold `serverProtocol` (`http` or `https`)
|
|
- `server/data/variables.json` can now also hold `serverPort` (1-65535)
|
|
- When `serverProtocol` is `https`, the certificate must match the configured `serverHost` or IP
|
|
|
|
## Main commands
|
|
|
|
- `npm run dev` starts Angular, the server, and Electron
|
|
- `npm run electron:dev` starts Angular and Electron
|
|
- `npm run server:dev` starts only the server
|
|
- `npm run build` builds the Angular client
|
|
- `npm run build:electron` builds the Electron code
|
|
- `npm run build:all` builds client, Electron, and server
|
|
- `npm run lint` runs ESLint
|
|
- `npm run lint:fix` formats templates, sorts template props, and fixes lint issues
|
|
- `npm run test` runs Angular tests
|
|
|
|
## Server project
|
|
|
|
The code in `server/` is a small Node and TypeScript service.
|
|
It handles the public server directory, join requests, websocket updates, and Klipy routes.
|
|
|
|
Inside `server/`:
|
|
|
|
- `npm run dev` starts the server with reload
|
|
- `npm run build` compiles to `dist/`
|
|
- `npm run start` runs the compiled server
|