Skip to content

Open-source gym & body-weight tracker, now in the App Store (iPhone + Apple Watch) and as an Android APK. Plan routines, log workouts, see which muscles are trained, import from Strong/Hevy/FitNotes. Self-host it or use it on the phone alone.

Umzug nach gitea.com: Images, Klon-URL, Anlaufstellen und CI umgestellt

Duarte Santosf94fa7c0e324
diff --git a/.gitea/ISSUE_TEMPLATE/bug_report.yml b/.gitea/ISSUE_TEMPLATE/bug_report.yml
new file mode 100644
index 000000000..dfc821eab
--- /dev/null
+++ b/.gitea/ISSUE_TEMPLATE/bug_report.yml
@@ -0,0 +1,60 @@
+name: Bug report
+description: Something in openGym is broken or not working as expected
+labels: ["bug"]
+body:
+ - type: textarea
+ id: what-happened
+ attributes:
+ label: What did you do?
+ description: Steps to reproduce, as precisely as you can.
+ placeholder: |
+ 1. Go to '...'
+ 2. Click on '...'
+ 3. See error
+ validations:
+ required: true
+
+ - type: textarea
+ id: expected
+ attributes:
+ label: What did you expect to happen?
+ validations:
+ required: true
+
+ - type: textarea
+ id: actual
+ attributes:
+ label: What happened instead?
+ description: Include error messages, console output, or screenshots if you have them.
+ validations:
+ required: true
+
+ - type: dropdown
+ id: setup
+ attributes:
+ label: How are you running openGym?
+ options:
+ - Self-hosted (docker compose)
+ - Frontend dev server (npm run dev)
+ - Other / not sure
+ validations:
+ required: true
+
+ - type: input
+ id: environment
+ attributes:
+ label: Browser & OS
+ placeholder: e.g. Safari 17 on iOS 18, Chrome 126 on Android
+ validations:
+ required: true
+
+ - type: checkboxes
+ id: passkey
+ attributes:
+ label: Is this about login / passkeys?
+ description: >
+ Most login issues are an `RP_ID`/`ORIGIN` mismatch — check your `.env` against the
+ domain you're accessing openGym from before reporting. See the
+ [self-hosting guide](../../docs/SELF_HOSTING.md).
+ options:
+ - label: Yes, this is a login/passkey issue and I've already checked RP_ID/ORIGIN
diff --git a/.gitea/ISSUE_TEMPLATE/config.yml b/.gitea/ISSUE_TEMPLATE/config.yml
new file mode 100644
index 000000000..ff525f9c7
--- /dev/null
+++ b/.gitea/ISSUE_TEMPLATE/config.yml
@@ -0,0 +1,14 @@
+# gitea.com has no Discussions, so questions and ideas are issues here — labelled, so they
+# are not mistaken for agreed-on work. Blank issues stay off: the forms ask for the two
+# things that otherwise cost a round-trip every time (how it is running, and RP_ID/ORIGIN).
+blank_issues_enabled: false
+contact_links:
+ - name: Self-hosting guide
+ url: https://gitea.com/DuarteSantos/openGym/src/branch/main/docs/SELF_HOSTING.md
+ about: Passkey login failing, reverse proxies, HTTPS, Docker — most login trouble is an RP_ID/ORIGIN mismatch and is answered here.
+ - name: Contributing guide
+ url: https://gitea.com/DuarteSantos/openGym/src/branch/main/CONTRIBUTING.md
+ about: Project layout, dev setup and guidelines before you open a PR.
+ - name: Changelog
+ url: https://gitea.com/DuarteSantos/openGym/src/branch/main/CHANGELOG.md
+ about: What changed in each release, newest first.
diff --git a/.gitea/ISSUE_TEMPLATE/feature_request.yml b/.gitea/ISSUE_TEMPLATE/feature_request.yml
new file mode 100644
index 000000000..8813faacf
--- /dev/null
+++ b/.gitea/ISSUE_TEMPLATE/feature_request.yml
@@ -0,0 +1,29 @@
+name: Feature request
+description: Suggest an idea or improvement for openGym
+labels: ["enhancement"]
+body:
+ - type: textarea
+ id: problem
+ attributes:
+ label: What problem does this solve?
+ description: What are you trying to do that openGym doesn't support today?
+ validations:
+ required: true
+
+ - type: textarea
+ id: proposal
+ attributes:
+ label: Proposed approach
+ description: How would you like it to work? Rough ideas are fine.
+ validations:
+ required: true
+
+ - type: checkboxes
+ id: deps
+ attributes:
+ label: Dependencies
+ description: >
+ openGym is intentionally dependency-light — new packages (front or back) are a hard
+ sell. See [CONTRIBUTING.md](../../CONTRIBUTING.md).
+ options:
+ - label: This doesn't require adding a new dependency
diff --git a/.gitea/workflows/docker-publish.yml b/.gitea/workflows/docker-publish.yml
new file mode 100644
index 000000000..d344da50a
--- /dev/null
+++ b/.gitea/workflows/docker-publish.yml
@@ -0,0 +1,86 @@
+# Publishes the two images to the gitea.com container registry, replacing GHCR.
+#
+# Images land at gitea.com/duartesantos/opengym-{api,web} and are what
+# `docker compose pull` fetches.
+#
+# As on GitHub, a *published release* is the trigger, never a bare tag push: the
+# versioning rule consolidates unreleased tags, and a deleted tag does not delete
+# the image tags it already pushed — dependency bots then read the orphan as a
+# newer series (that was issue #87 on the old repo).
+#
+# Needs one repository secret: PACKAGES_TOKEN — a gitea.com token with
+# write:package scope (Settings → Applications → Generate New Token). The built-in
+# token cannot write packages.
+name: Publish Docker images
+
+on:
+ push:
+ branches: [main]
+ release:
+ types: [published]
+ workflow_dispatch:
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ include:
+ - image: api
+ context: ./api
+ file: ./api/Dockerfile
+ - image: web
+ context: .
+ file: ./web/Dockerfile
+ steps:
+ - uses: actions/checkout@v4
+
+ - name: Lowercase owner (registry names must be lowercase)
+ id: repo
+ run: echo "owner=$(echo '${{ github.repository_owner }}' | tr '[:upper:]' '[:lower:]')" >> "$GITHUB_OUTPUT"
+
+ - name: Set version metadata
+ id: version_meta
+ run: |
+ # On a release the ref is refs/tags/vX.Y.Z; on a main push it is a branch ref,
+ # which would otherwise label the image "refs/heads/main".
+ case "$GITHUB_REF" in
+ refs/tags/*) VERSION="${GITHUB_REF#refs/tags/}" ;;
+ *) VERSION="main-${GITHUB_SHA::7}" ;;
+ esac
+ echo "VERSION=$VERSION" >> $GITHUB_OUTPUT
+ echo "VCS_REF=${GITHUB_SHA}" >> $GITHUB_OUTPUT
+ echo "BUILD_DATE=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> $GITHUB_OUTPUT
+
+ - uses: docker/setup-qemu-action@v3
+ - uses: docker/setup-buildx-action@v3
+
+ - uses: docker/login-action@v3
+ with:
+ registry: gitea.com
+ username: ${{ github.repository_owner }}
+ password: ${{ secrets.PACKAGES_TOKEN }}
+
+ - uses: docker/metadata-action@v5
+ id: meta
+ with:
+ images: gitea.com/${{ steps.repo.outputs.owner }}/opengym-${{ matrix.image }}
+ tags: |
+ type=raw,value=latest,enable={{is_default_branch}}
+ type=semver,pattern={{version}}
+ type=semver,pattern={{major}}.{{minor}}
+
+ # No cache-from/to: the GHCR copy used type=gha, which is a GitHub-hosted
+ # service and is not there on gitea.com's runners.
+ - uses: docker/build-push-action@v6
+ with:
+ context: ${{ matrix.context }}
+ file: ${{ matrix.file }}
+ platforms: linux/amd64,linux/arm64
+ build-args: |
+ VERSION=${{ steps.version_meta.outputs.VERSION }}
+ VCS_REF=${{ steps.version_meta.outputs.VCS_REF }}
+ BUILD_DATE=${{ steps.version_meta.outputs.BUILD_DATE }}
+ push: true
+ tags: ${{ steps.meta.outputs.tags }}
+ labels: ${{ steps.meta.outputs.labels }}
diff --git a/.gitea/workflows/test.yml b/.gitea/workflows/test.yml
new file mode 100644
index 000000000..f6da78ecc
--- /dev/null
+++ b/.gitea/workflows/test.yml
@@ -0,0 +1,38 @@
+# Same suite as .github/workflows/test.yml, run by gitea.com's Actions runners.
+# The GitHub copy is kept for the day that account comes back; this one is what
+# actually gates contributions today.
+name: Tests
+
+on:
+ pull_request:
+ paths:
+ - 'frontend/**'
+ - 'mcp/**'
+ - '.gitea/workflows/test.yml'
+ push:
+ branches: [main]
+ paths:
+ - 'frontend/**'
+ - 'mcp/**'
+ - '.gitea/workflows/test.yml'
+ workflow_dispatch:
+
+concurrency:
+ group: test-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ test:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ # node:22-alpine in web/Dockerfile and api/Dockerfile — CI must match production.
+ - uses: actions/setup-node@v4
+ with:
+ node-version: 22
+ cache: npm
+ cache-dependency-path: frontend/package-lock.json
+ - run: npm ci
+ working-directory: frontend
+ - run: npm test
+ working-directory: frontend
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index a33bc0466..7826a982e 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -55,13 +55,14 @@ cd frontend && npm test
| You have | Goes to |
| --- | --- |
-| A question, or self-hosting that won't behave | [Discussions → Q&A](https://github.com/DuarteSantos8/openGym/discussions/categories/q-a) |
-| An idea you're not sure about yet | [Discussions → Ideas](https://github.com/DuarteSantos8/openGym/discussions/categories/ideas) |
-| A reproducible bug | [Issues](https://github.com/DuarteSantos8/openGym/issues) |
+| A question, or self-hosting that won't behave | [An issue labelled `question`](https://gitea.com/DuarteSantos/openGym/issues) |
+| An idea you're not sure about yet | [An issue labelled `idea`](https://gitea.com/DuarteSantos/openGym/issues) |
+| A reproducible bug | [Issues](https://gitea.com/DuarteSantos/openGym/issues) |
| A change you've already built | A pull request |
-An answered question in Q&A is worth more than the same answer buried in a closed issue — the
-next person searching "passkey login fails behind my reverse proxy" actually finds it.
+gitea.com has no Discussions, so questions and ideas are issues too — just labelled, so nobody
+mistakes a question for agreed-on work. An answered question is worth more than the same answer
+in a chat log: the next person searching "passkey login fails behind my reverse proxy" finds it.
## Reporting bugs
diff --git a/README.md b/README.md
index fd12e3ef8..a060feee3 100644
--- a/README.md
+++ b/README.md
@@ -19,9 +19,9 @@ No account on someone else's server, no subscription, no ads. Just `docker compo
![Docker](https://img.shields.io/badge/Docker-compose-2496ED?style=flat-square&logo=docker&logoColor=white)
![No tracking](https://img.shields.io/badge/telemetry-none-f472b6?style=flat-square)
<br>
-![GitHub last commit](https://img.shields.io/github/last-commit/DuarteSantos8/openGym?style=flat-square)
-[![GitHub stars](https://img.shields.io/github/stars/DuarteSantos8/openGym?style=flat-square)](https://github.com/DuarteSantos8/openGym/stargazers)
-[![GitHub issues](https://img.shields.io/github/issues/DuarteSantos8/openGym?style=flat-square)](https://github.com/DuarteSantos8/openGym/issues)
+![Last commit](https://img.shields.io/gitea/last-commit/DuarteSantos/openGym?gitea_url=https%3A%2F%2Fgitea.com&style=flat-square)
+[![Stars](https://img.shields.io/gitea/stars/DuarteSantos/openGym?gitea_url=https%3A%2F%2Fgitea.com&style=flat-square)](https://gitea.com/DuarteSantos/openGym/stars)
+[![Issues](https://img.shields.io/gitea/issues/open/DuarteSantos/openGym?gitea_url=https%3A%2F%2Fgitea.com&style=flat-square)](https://gitea.com/DuarteSantos/openGym/issues)
</div>
@@ -39,11 +39,11 @@ No account on someone else's server, no subscription, no ads. Just `docker compo
<div align="center">
-### [🌐 opengym.duarte-santos.ch](https://opengym.duarte-santos.ch) · [▶ Try the live demo](https://duartesantos8.github.io/openGym/)
+### [🌐 opengym.duarte-santos.ch](https://opengym.duarte-santos.ch) · [📦 Source on gitea.com](https://gitea.com/DuarteSantos/openGym)
-No signup, nothing to install — it runs entirely in your browser on example data.<br>
-<sub>There's no server behind the demo, so passkey sign-in, sync across devices and the
-admin dashboard only exist in a self-hosted instance.</sub>
+Screenshots, docs and the APK download live on the site.<br>
+<sub>The browser demo was hosted on GitHub Pages and is offline while that account is
+suspended — self-host it (below) or sideload the Android app to try it for real.</sub>
</div>
@@ -92,7 +92,7 @@ as a home-screen app, passkey sign-in, offline support, sync across your phone a
You need [Docker](https://docs.docker.com/get-docker/) with Compose.
```bash
-git clone https://github.com/DuarteSantos8/openGym
+git clone https://gitea.com/DuarteSantos/openGym
cd openGym
cp .env.example .env
docker compose pull # grab prebuilt images (amd64 + arm64) — skip to build from source instead
@@ -101,7 +101,7 @@ docker compose up -d
Open **http://localhost:8080**, tap **Create profile**, and you're in. First launch downloads
the exercise media (~140 MB) once. Prefer building the images yourself instead of pulling from
-`ghcr.io`? Drop the `pull` step and run `docker compose up -d --build` — you don't need Node or
+`gitea.com`? Drop the `pull` step and run `docker compose up -d --build` — you don't need Node or
a build step locally either way.
> Want it reachable from your phone over the internet with passkeys? You'll need an HTTPS
@@ -202,15 +202,18 @@ in the Docker build.
## Community
-- **[Q&A](https://github.com/DuarteSantos8/openGym/discussions/categories/q-a)** — self-hosting
- help, passkey/login trouble, "how do I…". Most login problems turn out to be an `RP_ID`/`ORIGIN`
- mismatch.
-- **[Ideas](https://github.com/DuarteSantos8/openGym/discussions/categories/ideas)** — features
- worth talking through before anyone writes code.
-- **[Show and tell](https://github.com/DuarteSantos8/openGym/discussions/categories/show-and-tell)**
- — your setup, your plan templates, whatever you built on top.
-- **[Issues](https://github.com/DuarteSantos8/openGym/issues)** — bugs, and work that's already
- been agreed on.
+- **[Issues](https://gitea.com/DuarteSantos/openGym/issues)** — bugs, questions, self-hosting
+ help and ideas. gitea.com has no Discussions, so it all lives in one tracker: label a question
+ `question` and an idea `idea`, and it gets treated as one rather than as agreed-on work.
+- **Login trouble?** Most of it is an `RP_ID`/`ORIGIN` mismatch — check
+ [docs/SELF_HOSTING.md](docs/SELF_HOSTING.md) before opening an issue.
+- **Pull requests** — [open one on gitea.com](https://gitea.com/DuarteSantos/openGym/pulls); see
+ [CONTRIBUTING.md](CONTRIBUTING.md).
+
+> **On the GitHub repo:** `github.com/DuarteSantos8/openGym` is offline because the account was
+> suspended. gitea.com is the home of the project until that is resolved — same history, same
+> tags, same releases. Old GitHub issue and PR numbers in [CHANGELOG.md](CHANGELOG.md) are kept
+> as plain references; they don't map onto gitea's numbering.
## Contributing
diff --git a/SECURITY.md b/SECURITY.md
index 76290cb9f..71443b93f 100644
--- a/SECURITY.md
+++ b/SECURITY.md
@@ -8,7 +8,7 @@ need — what the app protects you from and what it doesn't.
Only the **latest release**. Releases are semver tags (`v1.0.0` → `v1.2.3`, see
[CHANGELOG.md](CHANGELOG.md)); there is no LTS or maintenance branch and older tags are never
-patched. A fix ships in the next release and in the `latest` images on ghcr.io.
+patched. A fix ships in the next release and in the `latest` images on gitea.com.
Updating a self-hosted instance:
@@ -18,14 +18,13 @@ git pull && docker compose pull && docker compose up -d
## Reporting a vulnerability
-Use GitHub's private vulnerability reporting — repo **Security** tab → **Report a vulnerability**:
+The project moved to gitea.com, which has no private-advisory feature. So: open an issue on
+<https://gitea.com/DuarteSantos/openGym/issues> saying only *"I need a private channel for a
+security report"* — no details, no repro, no version — and you'll get an address to send it to
+within a couple of days.
-<https://github.com/DuarteSantos8/openGym/security/advisories/new>
-
-> Private reporting has to be switched on in the repository settings for that link to work
-> (Settings → Advanced Security → Private vulnerability reporting). If it 404s, open a normal
-> issue saying only *"I need a private channel for a security report"* — no details, no repro —
-> and it will be enabled.
+> The GitHub repo and its private vulnerability reporting are gone with the suspended account;
+> `github.com/DuarteSantos8/openGym/security/advisories/new` no longer resolves.
Please don't put a working exploit in a public issue if it can be used against other people's
instances. Everything else (a crash you can only trigger on your own box, a scanner warning)
@@ -50,7 +49,7 @@ in the thread; there's no objection, and no request to sit on it indefinitely.
change a signed-in user's data.
- **Shipped deployment config** — `docker-compose.yml`, `web/nginx.conf`, the two Dockerfiles:
a default that exposes something a self-hoster wouldn't expect to be exposed.
-- **The published images** `ghcr.io/duartesantos8/opengym-api` and `-web`.
+- **The published images** `gitea.com/duartesantos/opengym-api` and `-web`.
## Out of scope
diff --git a/api/Dockerfile b/api/Dockerfile
index e924c28b4..c0d4065c3 100644
--- a/api/Dockerfile
+++ b/api/Dockerfile
@@ -4,12 +4,12 @@ ARG VERSION=dev
ARG VCS_REF=dev
ARG BUILD_DATE=unknown
-LABEL maintainer="Duarte Santos https://github.com/DuarteSantos8" \
+LABEL maintainer="Duarte Santos https://gitea.com/DuarteSantos" \
org.opencontainers.image.title="opengym-api" \
org.opencontainers.image.description="Backend for Self-hosted gym & body-weight tracker — plan routines, log workouts (supersets & cardio too), track your weight and progress, passkey login. Your data, your server." \
- org.opencontainers.image.source="https://github.com/DuarteSantos8/openGym" \
- org.opencontainers.image.url="https://ghcr.io/duartesantos8/opengym-api" \
- org.opencontainers.image.documentation="https://github.com/DuarteSantos8/openGym#readme" \
+ org.opencontainers.image.source="https://gitea.com/DuarteSantos/openGym" \
+ org.opencontainers.image.url="https://gitea.com/DuarteSantos/-/packages/container/opengym-api" \
+ org.opencontainers.image.documentation="https://gitea.com/DuarteSantos/openGym#readme" \
org.opencontainers.image.licenses="AGPL-3.0-or-later" \
org.opencontainers.image.version=$VERSION \
org.opencontainers.image.revision=$VCS_REF \
diff --git a/docker-compose.yml b/docker-compose.yml
index 21c9dae01..3da2b2ff7 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -24,7 +24,7 @@ services:
# Passkey auth + per-user data (Node, no framework).
# image: prebuilt (docker compose pull). build: from source (docker compose up --build).
api:
- image: ghcr.io/duartesantos8/opengym-api:latest
+ image: gitea.com/duartesantos/opengym-api:latest
build: ./api
restart: unless-stopped
env_file: .env
@@ -39,7 +39,7 @@ services:
# Builds the React frontend (multi-stage) and serves it, proxying /api → api
# and the exercise media from the shared volume. Single origin for passkeys.
web:
- image: ghcr.io/duartesantos8/opengym-web:latest
+ image: gitea.com/duartesantos/opengym-web:latest
build:
context: .
dockerfile: web/Dockerfile
diff --git a/docs/SELF_HOSTING.md b/docs/SELF_HOSTING.md
index 79afa71ea..956c20821 100644
--- a/docs/SELF_HOSTING.md
+++ b/docs/SELF_HOSTING.md
@@ -8,10 +8,10 @@ This guide takes you from "just cloned it" to "using it from my phone over the i
Requirements: [Docker](https://docs.docker.com/get-docker/) with the Compose plugin.
```bash
-git clone https://github.com/DuarteSantos8/openGym
+git clone https://gitea.com/DuarteSantos/openGym
cd openGym
cp .env.example .env
-docker compose pull # prebuilt images from ghcr.io (amd64 + arm64) — or skip and build from source
+docker compose pull # prebuilt images from gitea.com (amd64 + arm64) — or skip and build from source
docker compose up -d
```
diff --git a/frontend/src/lib/demo.js b/frontend/src/lib/demo.js
index 05f5ed1fb..3fe28ce24 100644
--- a/frontend/src/lib/demo.js
+++ b/frontend/src/lib/demo.js
@@ -11,4 +11,4 @@
// lands in a self-hosted bundle.
export const DEMO = import.meta.env.VITE_DEMO === '1'
export const DEMO_SEEDED = 'gym_demo_seeded_v1'
-export const REPO = 'https://github.com/DuarteSantos8/openGym'
+export const REPO = 'https://gitea.com/DuarteSantos/openGym'
diff --git a/frontend/src/views/Settings.jsx b/frontend/src/views/Settings.jsx
index 4b3508c2a..ed867fe48 100644
--- a/frontend/src/views/Settings.jsx
+++ b/frontend/src/views/Settings.jsx
@@ -196,7 +196,7 @@ export default function Settings() {
<div className="dim small" style={{ textAlign: 'center', marginTop: 4, lineHeight: 1.6 }}>
openGym · {t('free & open source (AGPL v3)')}<br />
- <a href="https://github.com/DuarteSantos8/openGym" target="_blank" rel="noopener">source code</a> · exercise data: hasaneyldrm/exercises-dataset (CC)
+ <a href="https://gitea.com/DuarteSantos/openGym" target="_blank" rel="noopener">source code</a> · exercise data: hasaneyldrm/exercises-dataset (CC)
</div>
</div>
}
diff --git a/web/Dockerfile b/web/Dockerfile
index 1c2adf7ba..56d4014d3 100644
--- a/web/Dockerfile
+++ b/web/Dockerfile
@@ -19,12 +19,12 @@ ARG VERSION=dev
ARG VCS_REF=dev
ARG BUILD_DATE=unknown
-LABEL maintainer="Duarte Santos https://github.com/DuarteSantos8" \
+LABEL maintainer="Duarte Santos https://gitea.com/DuarteSantos" \
org.opencontainers.image.title="opengym-web" \
org.opencontainers.image.description="Frontend for Self-hosted gym & body-weight tracker — plan routines, log workouts (supersets & cardio too), track your weight and progress, passkey login. Your data, your server." \
- org.opencontainers.image.source="https://github.com/DuarteSantos8/openGym" \
- org.opencontainers.image.url="https://ghcr.io/duartesantos8/opengym-web" \
- org.opencontainers.image.documentation="https://github.com/DuarteSantos8/openGym#readme" \
+ org.opencontainers.image.source="https://gitea.com/DuarteSantos/openGym" \
+ org.opencontainers.image.url="https://gitea.com/DuarteSantos/-/packages/container/opengym-web" \
+ org.opencontainers.image.documentation="https://gitea.com/DuarteSantos/openGym#readme" \
org.opencontainers.image.licenses="AGPL-3.0-or-later" \
org.opencontainers.image.version=$VERSION \
org.opencontainers.image.revision=$VCS_REF \