feat(ci): publish container images to Forgejo registry
Add image.yaml workflow targeting forgejo.coulomb.social; update Dockerfile for Forgejo PyPI secret names. Point pyproject issue-core index at Forgejo (uv.lock regen blocked until issue-core is published there).
This commit is contained in:
parent
1061f3ea3d
commit
050942ffc1
3 changed files with 73 additions and 14 deletions
22
Dockerfile
22
Dockerfile
|
|
@ -2,12 +2,12 @@
|
|||
#
|
||||
# Build:
|
||||
# docker build \
|
||||
# --secret id=gitea_pypi_user,env=GITEA_PYPI_USER \
|
||||
# --secret id=gitea_pypi_password,env=GITEA_PYPI_TOKEN \
|
||||
# -t gitea.coulomb.social/coulomb/vergabe-teilnahme:<tag> .
|
||||
# --secret id=forgejo_pypi_user,env=FORGEJO_PYPI_USER \
|
||||
# --secret id=forgejo_pypi_password,env=FORGEJO_PYPI_TOKEN \
|
||||
# -t forgejo.coulomb.social/coulomb/vergabe-teilnahme:<tag> .
|
||||
#
|
||||
# The optional secrets let uv authenticate to the Gitea Python package
|
||||
# registry when resolving issue-core.
|
||||
# Optional secrets authenticate to the Forgejo Python package registry
|
||||
# when resolving issue-core.
|
||||
|
||||
|
||||
# ─── Stage 1 ─── Vite + Tailwind asset build ────────────────────────────────
|
||||
|
|
@ -41,14 +41,14 @@ COPY --from=ghcr.io/astral-sh/uv:0.5.11 /uv /usr/local/bin/uv
|
|||
|
||||
WORKDIR /app
|
||||
COPY pyproject.toml uv.lock ./
|
||||
RUN --mount=type=secret,id=gitea_pypi_user,required=false \
|
||||
--mount=type=secret,id=gitea_pypi_password,required=false \
|
||||
RUN --mount=type=secret,id=forgejo_pypi_user,required=false \
|
||||
--mount=type=secret,id=forgejo_pypi_password,required=false \
|
||||
sh -eu -c '\
|
||||
if [ -f /run/secrets/gitea_pypi_user ]; then \
|
||||
export UV_INDEX_GITEA_USERNAME="$(cat /run/secrets/gitea_pypi_user)"; \
|
||||
if [ -f /run/secrets/forgejo_pypi_user ]; then \
|
||||
export UV_INDEX_FORGEJO_USERNAME="$(cat /run/secrets/forgejo_pypi_user)"; \
|
||||
fi; \
|
||||
if [ -f /run/secrets/gitea_pypi_password ]; then \
|
||||
export UV_INDEX_GITEA_PASSWORD="$(cat /run/secrets/gitea_pypi_password)"; \
|
||||
if [ -f /run/secrets/forgejo_pypi_password ]; then \
|
||||
export UV_INDEX_FORGEJO_PASSWORD="$(cat /run/secrets/forgejo_pypi_password)"; \
|
||||
fi; \
|
||||
uv sync --no-dev --no-install-project \
|
||||
'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue