Merge pull request #17 from 0XC7R/patch-1
Added <details> + summary for shorter readme
This commit is contained in:
@@ -8,6 +8,10 @@
|
|||||||
|
|
||||||
Hello, I made this project for fun.
|
Hello, I made this project for fun.
|
||||||
|
|
||||||
|
It is written using a combination of Typescript + Node.JS for the server and GOLang for the client. <br>
|
||||||
|
Connections are done via encrypted websockets to connect to the server from the client. <br>
|
||||||
|
You need to use docker to get this to run easier/for quicker deployment. <br>
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
- [Quick Start (Docker)](#quick-start-docker)
|
- [Quick Start (Docker)](#quick-start-docker)
|
||||||
@@ -24,6 +28,10 @@ If you just want it running fast, use this.
|
|||||||
|
|
||||||
> **⚠️ The compose file below is for Linux ONLY.** If you are on **Windows** or **macOS**, use `docker-compose.windows.yml` instead. See [Docker Install By OS](#docker-install-by-os) for the correct commands.
|
> **⚠️ The compose file below is for Linux ONLY.** If you are on **Windows** or **macOS**, use `docker-compose.windows.yml` instead. See [Docker Install By OS](#docker-install-by-os) for the correct commands.
|
||||||
|
|
||||||
|
<details>
|
||||||
|
|
||||||
|
<summary>Installation instructions for Linux</summary>
|
||||||
|
|
||||||
1. Create a `docker-compose.yml` file and paste this:
|
1. Create a `docker-compose.yml` file and paste this:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
@@ -114,10 +122,15 @@ Keep that file private and backed up.
|
|||||||
|
|
||||||
Default bootstrap login is `admin` / `admin` unless you set `OVERLORD_USER` and `OVERLORD_PASS`.
|
Default bootstrap login is `admin` / `admin` unless you set `OVERLORD_USER` and `OVERLORD_PASS`.
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
## Docker Install By OS
|
## Docker Install By OS
|
||||||
|
|
||||||
### Windows
|
### Windows
|
||||||
|
|
||||||
|
<details>
|
||||||
|
<summary>Installation instructions for Windows</summary>
|
||||||
|
<br>
|
||||||
Install Docker Desktop (includes Docker Compose):
|
Install Docker Desktop (includes Docker Compose):
|
||||||
|
|
||||||
- https://docs.docker.com/desktop/setup/install/windows-install/
|
- https://docs.docker.com/desktop/setup/install/windows-install/
|
||||||
@@ -217,8 +230,15 @@ docker --version
|
|||||||
docker compose version
|
docker compose version
|
||||||
```
|
```
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
### macOS
|
### macOS
|
||||||
|
|
||||||
|
|
||||||
|
<details>
|
||||||
|
<summary>Installation instructions for Mac</summary>
|
||||||
|
<br>
|
||||||
|
|
||||||
Install Docker Desktop:
|
Install Docker Desktop:
|
||||||
|
|
||||||
- https://docs.docker.com/desktop/setup/install/mac-install/
|
- https://docs.docker.com/desktop/setup/install/mac-install/
|
||||||
@@ -250,17 +270,29 @@ To rebuild after an update:
|
|||||||
docker compose -f docker-compose.windows.yml up --build -d
|
docker compose -f docker-compose.windows.yml up --build -d
|
||||||
```
|
```
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
## No Docker (.bat / .sh)
|
## No Docker (.bat / .sh)
|
||||||
|
|
||||||
If you do not want Docker, use the included scripts.
|
<details>
|
||||||
|
<summary>If you do not want Docker, use the included scripts.</summary>
|
||||||
|
<br>
|
||||||
|
|
||||||
Prerequisites for local (non-Docker) runs:
|
Prerequisites for local (non-Docker) runs:
|
||||||
|
|
||||||
- Bun in PATH
|
- Bun in PATH
|
||||||
- Go 1.21+ in PATH
|
- Go 1.21+ in PATH
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
### Windows
|
### Windows
|
||||||
|
|
||||||
|
<details>
|
||||||
|
<summary>Script instructions for Windows</summary>
|
||||||
|
<br>
|
||||||
|
|
||||||
Development mode (starts server + client):
|
Development mode (starts server + client):
|
||||||
|
|
||||||
```bat
|
```bat
|
||||||
@@ -273,14 +305,22 @@ Production mode (build + run server executable):
|
|||||||
start-prod.bat
|
start-prod.bat
|
||||||
```
|
```
|
||||||
|
|
||||||
Build client binaries:
|
Build client binaries (adds client builds to the build queue):
|
||||||
|
|
||||||
```bat
|
```bat
|
||||||
build-clients.bat
|
build-clients.bat
|
||||||
```
|
```
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
### Linux / macOS
|
### Linux / macOS
|
||||||
|
|
||||||
|
<details>
|
||||||
|
<summary>Installation instructions for Linux / Mac</summary>
|
||||||
|
<br>
|
||||||
|
|
||||||
Make scripts executable once:
|
Make scripts executable once:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@@ -311,6 +351,8 @@ Production mode:
|
|||||||
./start-prod.sh
|
./start-prod.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
## Production Package Scripts
|
## Production Package Scripts
|
||||||
|
|
||||||
Build a production-ready package where the server can still build client binaries at runtime.
|
Build a production-ready package where the server can still build client binaries at runtime.
|
||||||
@@ -334,6 +376,10 @@ Package output:
|
|||||||
|
|
||||||
## Docker Notes (TLS, reverse proxy, cache)
|
## Docker Notes (TLS, reverse proxy, cache)
|
||||||
|
|
||||||
|
<p>Here we will store some notes for you to read depending on what it is. Configs, work arounds etc.</p>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
### BuildKit cache for faster rebuilds
|
### BuildKit cache for faster rebuilds
|
||||||
|
|
||||||
`docker-compose.yml` includes `build.cache_from` and `build.cache_to` using `.docker-cache/buildx`.
|
`docker-compose.yml` includes `build.cache_from` and `build.cache_to` using `.docker-cache/buildx`.
|
||||||
@@ -344,6 +390,8 @@ Rebuild:
|
|||||||
docker compose up --build -d
|
docker compose up --build -d
|
||||||
```
|
```
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
### Runtime client build cache
|
### Runtime client build cache
|
||||||
|
|
||||||
The compose setup uses a persistent volume for runtime client builds:
|
The compose setup uses a persistent volume for runtime client builds:
|
||||||
@@ -352,34 +400,40 @@ The compose setup uses a persistent volume for runtime client builds:
|
|||||||
- mount: `/app/client-build-cache`
|
- mount: `/app/client-build-cache`
|
||||||
- env: `OVERLORD_CLIENT_BUILD_CACHE_DIR` (default `/app/client-build-cache`)
|
- env: `OVERLORD_CLIENT_BUILD_CACHE_DIR` (default `/app/client-build-cache`)
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
### Certbot TLS
|
### Certbot TLS
|
||||||
|
|
||||||
To use certbot certificates in production Docker:
|
To use certbot certificates in production Docker:
|
||||||
|
|
||||||
- Set `OVERLORD_TLS_CERTBOT_ENABLED=true`
|
#### Set:
|
||||||
- Set `OVERLORD_TLS_CERTBOT_DOMAIN=your-domain.com`
|
OVERLORD_TLS_CERTBOT_ENABLED=true
|
||||||
|
#### Set:
|
||||||
|
OVERLORD_TLS_CERTBOT_DOMAIN=your-domain.com
|
||||||
|
|
||||||
- Mount letsencrypt into container read-only (example: `/etc/letsencrypt:/etc/letsencrypt:ro`)
|
- Mount letsencrypt into container read-only (example: `/etc/letsencrypt:/etc/letsencrypt:ro`)
|
||||||
|
|
||||||
Default cert paths:
|
#### Default cert paths:
|
||||||
|
cert: /etc/letsencrypt/live/<domain>/fullchain.pem
|
||||||
|
key: /etc/letsencrypt/live/<domain>/privkey.pem
|
||||||
|
ca: /etc/letsencrypt/live/<domain>/chain.pem
|
||||||
|
|
||||||
- cert: `/etc/letsencrypt/live/<domain>/fullchain.pem`
|
#### Override with:
|
||||||
- key: `/etc/letsencrypt/live/<domain>/privkey.pem`
|
OVERLORD_TLS_CERTBOT_LIVE_PATH
|
||||||
- ca: `/etc/letsencrypt/live/<domain>/chain.pem`
|
OVERLORD_TLS_CERTBOT_CERT_FILE
|
||||||
|
OVERLORD_TLS_CERTBOT_KEY_FILE
|
||||||
|
OVERLORD_TLS_CERTBOT_CA_FILE
|
||||||
|
|
||||||
Override with:
|
<hr>
|
||||||
|
|
||||||
- `OVERLORD_TLS_CERTBOT_LIVE_PATH`
|
|
||||||
- `OVERLORD_TLS_CERTBOT_CERT_FILE`
|
|
||||||
- `OVERLORD_TLS_CERTBOT_KEY_FILE`
|
|
||||||
- `OVERLORD_TLS_CERTBOT_CA_FILE`
|
|
||||||
|
|
||||||
### Reverse proxy TLS offload (Render, etc.)
|
### Reverse proxy TLS offload (Render, etc.)
|
||||||
|
|
||||||
If your platform terminates TLS before traffic reaches Overlord, set:
|
#### If your platform terminates TLS before traffic reaches Overlord, set:
|
||||||
|
|
||||||
- `OVERLORD_TLS_OFFLOAD=true`
|
OVERLORD_TLS_OFFLOAD=true
|
||||||
- `OVERLORD_HEALTHCHECK_URL=http://localhost:5173/health`
|
OVERLORD_HEALTHCHECK_URL=http://localhost:5173/health
|
||||||
- `OVERLORD_PUBLISH_HOST=127.0.0.1` (recommended for local proxies like ngrok)
|
OVERLORD_PUBLISH_HOST=127.0.0.1
|
||||||
|
(recommended for local proxies like ngrok)
|
||||||
|
|
||||||
When enabled:
|
When enabled:
|
||||||
|
|
||||||
@@ -388,6 +442,8 @@ When enabled:
|
|||||||
- health checks should use `http://localhost:$PORT/health` inside the container
|
- health checks should use `http://localhost:$PORT/health` inside the container
|
||||||
- do not expose internal container HTTP port directly to the internet
|
- do not expose internal container HTTP port directly to the internet
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
For ngrok/local reverse proxy use, a common setup is:
|
For ngrok/local reverse proxy use, a common setup is:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -402,6 +458,8 @@ Then point ngrok at local HTTP:
|
|||||||
ngrok http http://127.0.0.1:5173
|
ngrok http http://127.0.0.1:5173
|
||||||
```
|
```
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
Notes:
|
Notes:
|
||||||
|
|
||||||
- Keep `HOST=0.0.0.0` inside the container. Limiting exposure should be done with publish binding (`OVERLORD_PUBLISH_HOST`), not server bind host.
|
- Keep `HOST=0.0.0.0` inside the container. Limiting exposure should be done with publish binding (`OVERLORD_PUBLISH_HOST`), not server bind host.
|
||||||
|
|||||||
Reference in New Issue
Block a user