add 000-configs/, dashboard, templates, .obsidian/, bin/, model-identity

This commit is contained in:
stateofshit
2026-07-29 13:29:47 +00:00
parent c22bd80fe1
commit 36eca4ca89
31 changed files with 1127 additions and 17 deletions
+202
View File
@@ -0,0 +1,202 @@
# GitHub CLI (gh) Instructions for Open WebUI Models
`gh` is the GitHub CLI — v2.96.0, fully installed and authenticated as **`stateofshit`**.
This document covers how any model on this server can use `gh` for repo management, issues, PRs, and everything GitHub-related.
---
## Quick Reference
```bash
gh --help # full help
gh auth status # confirm you're logged in
gh repo list # list all repos
gh repo view <repo> # view a repo
gh issue list # list issues in current dir's repo
gh pr create # create a pull request
```
---
## Authentication Status
Already logged in as **`stateofshit`** with token scopes: `admin:public_key`, `gist`, `read:org`, `repo`.
To check:
```bash
gh auth status
```
Expected output:
```
✓ Logged in to github.com account stateofshit
✓ Git operations protocol: ssh
✓ Token scopes: 'admin:public_key', 'gist', 'read:org', 'repo'
```
---
## Repo Management
### Create a new repo
```bash
gh repo create <owner>/<name> --private --description "what it is"
```
Flags:
- `--private` or `--public`
- `--clone` — also clone it locally after creating
- `--push` — push local branch to remote
### List repos
```bash
gh repo list stateofshit --limit 50
```
### View a repo
```bash
gh repo view stateofshit/shit_in_a_vault
```
### Delete a repo
⚠️ **Irreversible.**
```bash
gh repo delete stateofshit/shit_in_a_vault --yes
```
---
## Working With the Vault Repo
The vault lives at `/home/user/02-repos/shit_in_a_vault/`.
Before working with it, read the boot prompt:
```bash
cat /home/user/02-repos/shit_in_a_vault/04-models/model-boot.md
```
### Everyday flow
```bash
cd /home/user/02-repos/shit_in_a_vault
# Check status
git status
# Stage and commit
git add -A
git commit -m "description of changes"
# Push
git push
```
No need to authenticate — `git` uses SSH which is already set up via `~/.ssh/config`.
### Pull latest
```bash
cd /home/user/02-repos/shit_in_a_vault
git pull
```
---
## Issues
### Create an issue
```bash
gh issue create --title "Bug: thing broken" --body "Details here"
```
### List issues
```bash
gh issue list
```
### View / close
```bash
gh issue view <number>
gh issue close <number>
```
---
## Pull Requests
### Create a PR
```bash
# From a feature branch
git checkout -b my-feature
# ... make changes, commit, push ...
gh pr create --title "Add feature" --body "What it does"
```
### List / view / merge
```bash
gh pr list
gh pr view <number>
gh pr merge <number>
```
---
## Gists
```bash
# Create
gh gist create file.txt
# List
gh gist list
# View
gh gist view <gist-id>
```
---
## Working With Other Repos
Models can work with any repo `stateofshit` has access to.
### Clone any accessible repo
```bash
gh repo clone stateofshit/webby /home/user/02-repos/webby
```
Already cloned repos are in `/home/user/02-repos/`:
- `webby``stateofshit/webby`
- `shit_in_a_vault``stateofshit/shit_in_a_vault`
---
## Environment
- `gh` binary: `/usr/bin/gh` (system-installed)
- Config: `~/.config/gh/hosts.yml`
- Token is stored in that config — **do not expose it in chat or in files**
- Git protocol: SSH (key at `~/.ssh/github_openwebui`)
---
## Notes
- **Never** paste the token or `~/.config/gh/hosts.yml` contents into chat output.
- **Never** run `gh auth logout` — it will break all future model access.
- Deleting a repo is permanent. Use `--yes` with extreme care.
- `gh` respects the current directory's git remote. Run it inside a repo to act on that repo.
@@ -0,0 +1,95 @@
# Playwright Browser Instructions for Open WebUI Coding AI
Use Playwright when the user asks you to inspect, test, debug, screenshot, or interact with a real webpage or web app.
Playwright is available inside the Open WebUI terminal container.
## What Playwright Is For
Use Playwright for:
- checking whether a webpage actually renders
- taking screenshots of an app
- testing buttons, forms, menus, routing, and mobile layouts
- inspecting page text after JavaScript runs
- debugging frontend errors that do not show up with `curl`
- verifying `https://preview.boogerclub.com`
Do not use Playwright as a replacement for normal web search. Use it when browser rendering or interaction matters.
## Quick Commands
Take a screenshot:
```bash
npx playwright screenshot --browser=chromium https://example.com /home/user/example.png
```
Take a screenshot of the live Vite preview:
```bash
npx playwright screenshot --browser=chromium https://preview.boogerclub.com /home/user/preview.png
```
Open a mobile-sized screenshot:
```bash
npx playwright screenshot --browser=chromium --viewport-size=390,844 https://preview.boogerclub.com /home/user/preview-mobile.png
```
Generate a Playwright test scaffold in an app:
```bash
cd /home/user/projects/YOUR_APP
npm install -D @playwright/test
npx playwright install chromium
npx playwright test
```
## One-Off Page Inspection Script
For quick rendered-page inspection, create a temporary script like this:
```js
const { chromium } = require('playwright')
;(async () => {
const browser = await chromium.launch({ headless: true })
const page = await browser.newPage({ viewport: { width: 1440, height: 1000 } })
await page.goto('https://preview.boogerclub.com', { waitUntil: 'networkidle' })
console.log(await page.title())
console.log((await page.locator('body').innerText()).slice(0, 2000))
await page.screenshot({ path: '/home/user/preview.png', fullPage: true })
await browser.close()
})()
```
Run it with:
```bash
node script-name.js
```
## Current Verified State
Playwright Chromium has been installed and verified in this container.
Smoke test that passed:
```bash
cd /home/user
npx playwright screenshot --browser=chromium https://example.com /home/user/playwright-smoke.png
```
If Playwright later says browser binaries are missing, run:
```bash
npx playwright install chromium
```
If Chromium fails with missing shared libraries, run this from the host against the Open WebUI compose stack:
```bash
docker compose exec -u root open-terminal sh -lc 'cd /home/user && npx playwright install-deps chromium'
```
+26
View File
@@ -0,0 +1,26 @@
# Tools
Tool docs — CLI references, browser automation, frameworks, anything with a CLI or API.
## Naming
`TOOL_NAME_INSTRUCTIONS.md` — matches the existing convention from `/home/user/000-configs/`.
## Current
- `GH_CLI_INSTRUCTIONS.md` — GitHub CLI
- `PLAYWRIGHT_BROWSER_INSTRUCTIONS.md` — browser automation
- `VITE_PREVIEW_INSTRUCTIONS.md` — Vite preview server
## Adding a new tool doc
```bash
cd /home/user/02-repos/shit_in_a_vault/000-configs/tools
touch NEW_TOOL_INSTRUCTIONS.md
```
Include:
- Install location
- Auth status
- Common commands
- Server-specific quirks
@@ -0,0 +1,147 @@
# Vite Preview Instructions for Open WebUI Coding AI
Use this when the user asks to make a Vite/React app live, visible, public, previewable, or available at the preview URL.
## Public Preview URL
The stable public preview URL is:
```text
https://preview.boogerclub.com
```
Caddy on the host already proxies this hostname to the `open-terminal` container on port `5173`:
```text
preview.boogerclub.com -> open-terminal:5173
```
Do not change the Open WebUI URL. Open WebUI stays at:
```text
https://openwebui.boogerclub.com
```
## Where Apps Live
Inside the Open WebUI terminal container:
```text
/home/user/projects
/home/user/repos
```
On the host these map to:
```text
/home/ubuntu/openwebui/projects
/home/ubuntu/repos
```
## Start Command
For a Vite app, run this from the app directory:
```bash
npm run dev -- --host 0.0.0.0 --port 5173
```
Only one app can use the public preview slot at a time. If port `5173` is already in use, stop the old Vite dev server before starting the new one.
## Required Vite Host Allowlist
If the preview URL shows this error:
```text
Blocked request. This host ("preview.boogerclub.com") is not allowed.
To allow this host, add "preview.boogerclub.com" to `server.allowedHosts` in vite.config.js.
```
Add this to `vite.config.ts` or `vite.config.js`:
```ts
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
export default defineConfig({
plugins: [react()],
server: {
allowedHosts: ['preview.boogerclub.com'],
},
})
```
If the config already has a `server` block, add only:
```ts
allowedHosts: ['preview.boogerclub.com']
```
Then restart Vite with:
```bash
npm run dev -- --host 0.0.0.0 --port 5173
```
## Verification
From inside the terminal container, verify Vite is running:
```bash
curl -I http://127.0.0.1:5173
```
Expected result:
```text
HTTP/1.1 200 OK
```
From the public internet, verify the live preview:
```bash
curl -I https://preview.boogerclub.com
```
Expected result:
```text
HTTP/2 200
via: 1.1 Caddy
```
Also confirm Open WebUI still works:
```bash
curl -I https://openwebui.boogerclub.com
```
Expected result:
```text
HTTP/2 200
```
## Common Fixes
- `502` from `https://preview.boogerclub.com`: Caddy is up, but no Vite server is listening on `open-terminal:5173`. Start the app with the standard command.
- `Blocked request... host is not allowed`: add `preview.boogerclub.com` to `server.allowedHosts` in the app's Vite config and restart Vite.
- App works at `127.0.0.1:5173` but not the public URL: check `allowedHosts`, then check DNS for `preview.boogerclub.com`.
- Open WebUI should not be moved to the preview URL. Keep it on `https://openwebui.boogerclub.com`.
## Current Known Working Example
The current working example app is:
```text
/home/user/projects/candlestick-dashboard
```
It is configured with:
```ts
server: {
allowedHosts: ['preview.boogerclub.com'],
}
```