You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-[UI Development vs Production Mode](#ui-development-vs-production-mode)
@@ -218,6 +219,86 @@ All service URLs used by the test suite are defined in a single file:
218
219
```
219
220
220
221
Edit this file to change ports or hostnames for your environment. The `.env` file is loaded by both the shell scripts (`run-tests.sh`, `setup.sh`) and the Playwright TypeScript configuration. If the file is missing, all URLs fall back to their default `localhost` values.
222
+
## GitHub CLI
223
+
224
+
The dev container includes the [GitHub CLI](https://cli.github.com/) (`gh`). The GitHub CLI's authentication is reused by the GitHub MCP server for agentic development.
225
+
226
+
### Authentication
227
+
228
+
GitHub CLI authentication is **persisted across container rebuilds** using a bind mount. Credentials stored via `gh auth login` are saved and automatically available inside the container after a rebuild.
229
+
230
+
To authenticate for the first time:
231
+
232
+
```bash
233
+
gh auth login
234
+
```
235
+
236
+
Follow the prompts to authenticate via browser or token.
237
+
238
+
### Recommended: Use a Fine-Grained Personal Access Token
239
+
240
+
We strongly recommend authenticating with a **fine-grained personal access token (PAT)** rather than a full OAuth login. Fine-grained PATs let you limit exactly what `gh` can do on your behalf.
241
+
242
+
**To create a fine-grained PAT:**
243
+
244
+
1. Go to **GitHub → Settings → Developer settings → Personal access tokens → Fine-grained tokens**
245
+
2. Click **Generate new token**
246
+
3. Set an expiration date
247
+
4. Under **Repository access**, select only the repositories relevant to your work
248
+
5. Under **Permissions**, grant only what you need — a reasonable read-heavy baseline:
249
+
250
+
| Permission | Access |
251
+
|---|---|
252
+
| Contents | Read-only |
253
+
| Issues | Read and write |
254
+
| Pull requests | Read and write |
255
+
| Metadata | Read-only (required) |
256
+
| Actions | Read-only |
257
+
| Secrets | None |
258
+
| Administration | None |
259
+
260
+
6. Click **Generate token**, copy it, then run:
261
+
262
+
```bash
263
+
gh auth login --with-token <<<"your_token_here"
264
+
```
265
+
266
+
> Avoid granting `Administration`, `Secrets`, or `Members` permissions — these allow destructive or sensitive operations that are unlikely to be needed during normal development.
267
+
268
+
### Claude Code Restrictions
269
+
270
+
To prevent accidental or unintended destructive actions, Claude Code has been configured to **deny** the following `gh` commands in `.claude/settings.json`:
271
+
272
+
**Raw API access**
273
+
-`gh api` — bypasses all CLI safeguards; denied entirely
274
+
275
+
**Delete operations**
276
+
-`gh alias delete`, `gh cache delete`, `gh codespace delete`
0 commit comments