docs: update Tailscale IPs and node names to match live infrastructure
- ARCHITECTURE.md: orange → orangevps (100.79.111.61), update imrnes IP to 100.121.180.82, archlinux IP to 100.84.39.83, remove offline laptop node - README.md: update VPS table, env examples, troubleshooting IPs - CONTRIBUTING.md: fix VPS name and IP in deploy section Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
75da3af5b8
commit
28934aaafc
+8
-10
@@ -87,10 +87,9 @@ docker compose -f traefik.yml -f shared.yml -f scraper.yml up -d
|
|||||||
```mermaid
|
```mermaid
|
||||||
graph TB
|
graph TB
|
||||||
subgraph "Tailnet (100.64.0.0/10)"
|
subgraph "Tailnet (100.64.0.0/10)"
|
||||||
IMRNES["imrnes (100.108.1.124)"]
|
IMRNES["imrnes (100.121.180.82)"]
|
||||||
ORANGE["orange (100.96.248.86)"]
|
ORANGEVPS["orangevps (100.79.111.61)"]
|
||||||
ARCH["archlinux (100.114.19.66)"]
|
ARCH["archlinux (100.84.39.83)"]
|
||||||
LAPTOP["laptop-2f6e1iph (100.86.195.29)"]
|
|
||||||
end
|
end
|
||||||
|
|
||||||
subgraph "imrnes Services"
|
subgraph "imrnes Services"
|
||||||
@@ -98,7 +97,7 @@ graph TB
|
|||||||
REDIS[Redis]
|
REDIS[Redis]
|
||||||
end
|
end
|
||||||
|
|
||||||
subgraph "orange Containers"
|
subgraph "orangevps Containers"
|
||||||
TRAEFIK[Traefik :443]
|
TRAEFIK[Traefik :443]
|
||||||
SCRAPER[scraper-api :4091]
|
SCRAPER[scraper-api :4091]
|
||||||
end
|
end
|
||||||
@@ -106,9 +105,8 @@ graph TB
|
|||||||
TRAEFIK --> SCRAPER
|
TRAEFIK --> SCRAPER
|
||||||
|
|
||||||
style IMRNES fill:#3a7,color:#fff
|
style IMRNES fill:#3a7,color:#fff
|
||||||
style ORANGE fill:#37a,color:#fff
|
style ORANGEVPS fill:#37a,color:#fff
|
||||||
style ARCH fill:#773,color:#fff
|
style ARCH fill:#773,color:#fff
|
||||||
style LAPTOP fill:#777,color:#fff
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Container-to-Tailscale connectivity requires a systemd service that adds a route to the main routing table:
|
Container-to-Tailscale connectivity requires a systemd service that adds a route to the main routing table:
|
||||||
@@ -117,7 +115,7 @@ Container-to-Tailscale connectivity requires a systemd service that adds a route
|
|||||||
ip route add 100.64.0.0/10 dev tailscale0 table main
|
ip route add 100.64.0.0/10 dev tailscale0 table main
|
||||||
```
|
```
|
||||||
|
|
||||||
This is managed by `/etc/systemd/system/tailscale-routes.service` on the `orange` VPS.
|
This is managed by `/etc/systemd/system/tailscale-routes.service` on the `orangevps` VPS.
|
||||||
|
|
||||||
## Data Flow
|
## Data Flow
|
||||||
|
|
||||||
@@ -133,7 +131,7 @@ sequenceDiagram
|
|||||||
participant Redis as Redis (imrnes via Tailscale)
|
participant Redis as Redis (imrnes via Tailscale)
|
||||||
|
|
||||||
User->>DNS: asepharyana.my.id
|
User->>DNS: asepharyana.my.id
|
||||||
DNS->>User: A/AAAA record → orange VPS IP
|
DNS->>User: A/AAAA record → orangevps VPS IP
|
||||||
User->>Traefik: HTTPS request :443
|
User->>Traefik: HTTPS request :443
|
||||||
Traefik->>Traefik: TLS termination
|
Traefik->>Traefik: TLS termination
|
||||||
Traefik->>Traefik: Middleware chain (headers, rate-limit, buffer)
|
Traefik->>Traefik: Middleware chain (headers, rate-limit, buffer)
|
||||||
@@ -193,7 +191,7 @@ flowchart LR
|
|||||||
|
|
||||||
### VPS Deployment
|
### VPS Deployment
|
||||||
|
|
||||||
The `orange` VPS (Tailscale `100.96.248.86`) hosts all application containers:
|
The `orangevps` VPS (Tailscale `100.79.111.61`) hosts all application containers:
|
||||||
|
|
||||||
1. GitHub Actions SSHes into the VPS
|
1. GitHub Actions SSHes into the VPS
|
||||||
2. Production secrets are written as `.env`
|
2. Production secrets are written as `.env`
|
||||||
|
|||||||
+1
-1
@@ -175,7 +175,7 @@ Common scopes: `scraper`, `infra`, `ci`, `deps`
|
|||||||
- Updates compose manifests to use the new SHA tags
|
- Updates compose manifests to use the new SHA tags
|
||||||
|
|
||||||
6. **Deployment Pipeline** triggers after a successful Docker build:
|
6. **Deployment Pipeline** triggers after a successful Docker build:
|
||||||
- SSHes into the VPS (`orange`, Tailscale IP `100.96.248.86`)
|
- SSHes into the VPS (`orangevps`, Tailscale IP `100.79.111.61`)
|
||||||
- Pulls updated Docker images
|
- Pulls updated Docker images
|
||||||
- Recreates only the changed containers
|
- Recreates only the changed containers
|
||||||
- All services share the `app-shared-net` Docker network
|
- All services share the `app-shared-net` Docker network
|
||||||
|
|||||||
@@ -64,11 +64,10 @@ Refer to each service's own documentation for API docs.
|
|||||||
Semua VPS terhubung via **Tailscale**. Setiap VPS punya IP Tailscale dan service berkomunikasi antar VPS melalui Tailscale network (`100.64.0.0/10`).
|
Semua VPS terhubung via **Tailscale**. Setiap VPS punya IP Tailscale dan service berkomunikasi antar VPS melalui Tailscale network (`100.64.0.0/10`).
|
||||||
|
|
||||||
| VPS | Tailscale IP | Service |
|
| VPS | Tailscale IP | Service |
|
||||||
| :---------------- | :-------------- | :------------------------------------- |
|
| :--------- | :-------------- | :------------------------------------- |
|
||||||
| `imrnes` | `100.108.1.124` | PostgreSQL (`hub`), Redis |
|
| `imrnes` | `100.121.180.82` | PostgreSQL, Redis |
|
||||||
| `orange` | `100.96.248.86` | App containers (Traefik, 9Router, dll) |
|
| `orangevps` | `100.79.111.61` | App containers (Traefik, scraper-api) |
|
||||||
| `archlinux` | `100.114.19.66` | _(development machine)_ |
|
| `archlinux` | `100.84.39.83` | _(development machine)_ |
|
||||||
| `laptop-2f6e1iph` | `100.86.195.29` | _(offline)_ |
|
|
||||||
|
|
||||||
### Container → Tailscale Connectivity
|
### Container → Tailscale Connectivity
|
||||||
|
|
||||||
@@ -95,10 +94,10 @@ Service yang connect ke Tailscale IP:
|
|||||||
|
|
||||||
```env
|
```env
|
||||||
# PostgreSQL di imrnes
|
# PostgreSQL di imrnes
|
||||||
DATABASE_URL=postgres://user:pass@100.108.1.124:5432/dbname
|
DATABASE_URL=postgres://user:pass@100.121.180.82:5432/dbname
|
||||||
|
|
||||||
# Redis di imrnes
|
# Redis di imrnes
|
||||||
REDIS_URL=redis://100.108.1.124:6379
|
REDIS_URL=redis://100.121.180.82:6379
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Persistent Systemd Service
|
#### Persistent Systemd Service
|
||||||
@@ -160,7 +159,7 @@ docker exec <container> node -e "
|
|||||||
const net = require('net');
|
const net = require('net');
|
||||||
const c = new net.Socket();
|
const c = new net.Socket();
|
||||||
c.setTimeout(5000);
|
c.setTimeout(5000);
|
||||||
c.connect(5432, '100.108.1.124', () => { console.log('OK'); c.end(); });
|
c.connect(5432, '100.121.180.82', () => { console.log('OK'); c.end(); });
|
||||||
c.on('error', e => { console.log('FAIL:', e.code); });
|
c.on('error', e => { console.log('FAIL:', e.code); });
|
||||||
c.on('timeout', () => { console.log('TIMEOUT'); c.destroy(); });
|
c.on('timeout', () => { console.log('TIMEOUT'); c.destroy(); });
|
||||||
"
|
"
|
||||||
|
|||||||
Reference in New Issue
Block a user