Host on Gitea: forge.yaml, Gitea workflows, host-neutral links

- forge.yaml: the repository's host (Gitea at git.kenschiano.net, limited visibility);
  the "Report a run" collector, the page's links (data/public/links.json, filled in by
  site/build.js) and the dataset metadata read it
- collection/etl/forge.py: issues, pull requests (merge when checks succeed) and labels
  for Gitea and GitHub; `python -m collection forge ...`
- .gitea/workflows: CI and the daily update (pushes a branch, opens a pull request that
  merges itself, opens an issue when a source breaks); .github/workflows kept for GitHub
- docs: Gitea setup (REPO_SETTINGS), the bot reading atlas files from the repository

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UCzTd31GphpMXDhQqWrCMQ
This commit is contained in:
ekcSchiano
2026-11-12 02:46:17 +00:00
co-authored by Claude Opus 5.5
parent 8713ccff1a
commit 614bfcda7c
20 changed files with 479 additions and 47 deletions
+46
View File
@@ -1,5 +1,51 @@
# Repository settings
The Atlas is hosted on Gitea (`forge.yaml`: git.kenschiano.net). The GitHub repository and its GitHub Pages site are
paused while that account is suspended; their workflows stay in `.github/workflows/` for when it is back.
## Gitea: setting up the repository (once)
1. **Your account** on git.kenschiano.net (ask Ken), with 2FA on and your SSH key added (Settings → SSH / GPG Keys).
2. **Create the repository** `threshing-atlas` under your account, visibility **limited** (only people signed in to
the server), empty (no README or licence: they come from the push). Put your username in `forge.yaml` (`repo:`),
then `python -m collection build` and commit.
3. **Push** from your Mac copy:
```
cd ~/PycharmProjects/threshing-atlas
git remote rename origin github # keep the GitHub address for later
git remote add origin git@git.kenschiano.net:<you>/threshing-atlas.git
git push -u origin main
```
4. **Turn on Actions** (repository Settings → Units → Actions) and ask Ken which runner label the server has. The
workflows use `ubuntu-latest`; change `runs-on:` in `.gitea/workflows/*.yml` if it is different.
5. **Secrets** (Settings → Actions → Secrets):
| Secret | What it is | How to make it |
|---|---|---|
| `ATLAS_BOT_TOKEN` | lets the daily update push its branch, open the pull request and issues | your Settings → Applications → Generate token; permissions: repository read and write, issue read and write |
| `RAW_ARCHIVE_KEY` | encrypts the private raw store kept in the Actions cache between runs | any long random string (`openssl rand -base64 32`); keep a copy |
| `REDDIT_CLIENT_ID`, `REDDIT_CLIENT_SECRET` | optional: read the megathreads through the Reddit API | see "Data collection secrets" below |
6. **Protect main** (Settings → Branches → Add rule for `main`): require a pull request, enable status checks and
require the check from the CI workflow (it shows up as `CI / test` after its first run), and allow
"merge when checks succeed". Leave required approvals at 0 so the daily update can merge itself.
7. **The label** for reports: `python -m collection forge ensure-label --name "run report"` (with
`ATLAS_BOT_TOKEN` set), or create it under Issues → Labels.
The daily update then runs at 10:23 UTC; run it by hand from the Actions tab (workflow "Check sources for new data").
Locally, `python -m collection refresh` does the same.
## The page
The page is built by `node site/build.js` and viewed locally or published as a Claude artifact; Gitea has no Pages.
Its links (the repository, "Report a run") come from `forge.yaml` through `data/public/links.json`.
## GitHub (paused)
# Repository settings
Some settings live on GitHub, not in the code. Only the repository owner (ekcSchiano) can change them.
They go together: the ruleset makes CI a gate on `main`, auto-merge lets a pull request merge itself once
it passes, and the token lets the daily data update do that on its own.