`pip install fluksio && fluksio serve` on a machine with no Docker, no database and no configuration — which is the case this is for: a node on a cluster where ports cannot be opened. It makes its data directory, its key and an admin account, prints the password once, and serves. Pairing is `fluksio enroll <code> --portal …`, doing what the Settings screen does through the same function, before the engine starts and without one running — a machine nobody can route to has no browser pointed at it either. The portal serves the dashboard, so nothing is served here. Two things had to give way. `fastapi[standard]` pulls a cloud CLI that wants sentry-sdk 2.x while we pinned below it — no pip resolution existed, so the pin is lifted, which the comment beside it had been waiting for and which also lets the Python cap go. And `uv` is now a dependency rather than something to find on PATH: the Modules screen is how a data scientist installs torch, and it was quietly falling back to the engine's own interpreter. The CLI imports nothing from the engine before it has set DATA_DIR — the settings are built on the first import of core.config, and reaching it early put the database in the working directory. There is a test for that now, because the failure is silent. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
46 lines
1.4 KiB
YAML
46 lines
1.4 KiB
YAML
# Publish both distributions to PyPI on a version tag.
|
|
#
|
|
# Tags are the trigger rather than pushes to main: a release is a decision, and
|
|
# a version already on PyPI cannot be replaced.
|
|
name: Publish
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- "v*"
|
|
|
|
jobs:
|
|
publish:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.10"
|
|
- name: Set up uv
|
|
uses: astral-sh/setup-uv@v7
|
|
- name: The tag is what the packages say they are
|
|
# Publishing 0.2.0 from a v0.3.0 tag is the kind of thing nobody
|
|
# notices until an install pulls the wrong one.
|
|
run: |
|
|
version="${GITHUB_REF_NAME#v}"
|
|
for project in backend worker; do
|
|
declared=$(uv version --short --directory "$project")
|
|
[ "$declared" = "$version" ] || {
|
|
echo "$project declares $declared, tag says $version" >&2
|
|
exit 1
|
|
}
|
|
done
|
|
- run: uv build --all-packages --out-dir dist
|
|
- name: Both wheels install and run
|
|
run: |
|
|
uv run --no-project --with dist/fluksio_worker-*.whl fluksio-worker --help
|
|
uv run --no-project --with dist/fluksio-*.whl --with dist/fluksio_worker-*.whl \
|
|
fluksio --version
|
|
- name: Publish
|
|
env:
|
|
UV_PUBLISH_TOKEN: ${{ secrets.PYPI_TOKEN }}
|
|
run: uv publish dist/*
|