- Node.js (v18+)
- Go (v1.20+)
- Android Studio (for Android builds)
- Google Cloud Console Project (for OAuth keys)
The server is a lightweight Go application.
-
Navigate to the
Serverdirectory.cd Server -
Initialize dependencies (if not already done).
go mod init socket go get github.com/gorilla/websocket go get github.com/joho/godotenv go get github.com/mattn/go-sqlite3
-
Copy the example environment file:
cp .example.env .env
-
Ensure the following variables are configured in
.env:SESSION_SECRET: Secret key for HMAC token signing.TURN_HOST: URL/IP for the TURN relay server (optional for local dev).TURN_SECRET: Secret for deriving ephemeral TURN credentials (optional).
go run .The server listens on ws://localhost:9000.
The client is a React application using Vite and Capacitor.
-
Navigate to the
Clientdirectory.cd Client -
Install dependencies.
npm install
-
Configuration: Ensure you have valid Google OAuth credentials.
- Place
google-services.jsoninandroid/app/(for Android). - Configure Client IDs in your environment or constants.
- Place
The build command handles all preparation steps including:
- Building React application with Vite
- Syncing with Capacitor for Android
- Copying assets for Electron
npm run buildNote
This single command prepares the application for both Android and Electron platforms. You don't need to run separate build or sync commands.
After building, open the project in Android Studio:
npx cap open androidThen run the app from Android Studio on an emulator or physical device.
After building, start the Electron app:
npm run electron:start