Our Personal Data Server from scratch!
0

Configure Feed

Select the types of activity you want to include in your feed.

chore: add frontend service to docker compose

Signed-off-by: Trezy <tre@trezy.com>

author
Trezy
committer
Tangled
date (May 19, 2026, 7:46 PM +0300) commit 04f370aa parent 3fd8f7eb
+34 -3
+2
.gitignore
··· 4 4 result 5 5 frontend/node_modules/ 6 6 frontend/dist/ 7 + frontend/.pnpm-store 8 + frontend/.npmrc
+21
docker-compose.yaml
··· 57 57 depends_on: 58 58 - app 59 59 60 + frontend-dev: 61 + profiles: [dev] 62 + image: node:24-alpine 63 + working_dir: /app 64 + command: sh -c "corepack enable && corepack prepare pnpm@latest --activate && pnpm install --ignore-scripts && pnpm dev --host 0.0.0.0" 65 + environment: 66 + CI: "true" 67 + npm_config_store_dir: "/pnpm-store" 68 + VITE_API_URL: "http://app-dev:3000" 69 + VITE_HMR_PROTOCOL: "wss" 70 + VITE_HMR_HOST: "pds.test" 71 + VITE_HMR_PORT: "443" 72 + volumes: 73 + - ./frontend:/app 74 + - node_modules:/app/node_modules 75 + - pnpm_store:/pnpm-store 76 + depends_on: 77 + - app-dev 78 + 60 79 db: 61 80 image: postgres:18-alpine 62 81 environment: ··· 139 158 prometheus_data: 140 159 cargo_target: 141 160 cargo_registry: 161 + node_modules: 162 + pnpm_store: 142 163 certs:
+4 -3
frontend/src/lib/oauth.ts
··· 13 13 "account:*?action=manage", 14 14 ].join(" "); 15 15 16 - const CLIENT_ID = !(import.meta.env.DEV) 17 - ? `${globalThis.location.origin}/oauth-client-metadata.json` 18 - : `http://localhost/?scope=${SCOPES}`; 16 + const CLIENT_ID = 17 + !(import.meta.env.DEV) || globalThis.location?.hostname !== 'localhost' 18 + ? `${globalThis.location.origin}/oauth-client-metadata.json` 19 + : `http://localhost/?scope=${SCOPES}`; 19 20 20 21 const REDIRECT_URI = `${globalThis.location.origin}/app/`; 21 22
+7
frontend/vite.config.ts
··· 20 20 "/health": target, 21 21 "/u": target, 22 22 }, 23 + hmr: env.VITE_HMR_HOST 24 + ? { 25 + protocol: env.VITE_HMR_PROTOCOL || "wss", 26 + host: env.VITE_HMR_HOST, 27 + clientPort: parseInt(env.VITE_HMR_PORT || "443"), 28 + } 29 + : undefined, 23 30 }, 24 31 }; 25 32 });