A simplistic, opinionated remote update server implementing hawkBit™'s DDI API.
To set up, install the dependencies in pyproject.toml
with poetry install
. Then you can run gooseBit by running main.py
.
The first time you start gooseBit, you should change the default username and password inside settings.yaml
.
The default login credentials for testing are admin@goosebit.local
, admin
.
- SWUpdate used on device side.
Uploading firmware images through frontend. All files should follow the format {model}_{revision}_{version}
, where
version
is either a semantic version or a datetime version in the format YYYYMMDD-HHmmSS
.
First time a new device connects, its configuration data is requested. hw_model
and hw_revision
are captured from
the configuration data (both fall back to default
if not provided) which allows to distinguish different device
types and their revisions.
Once a device is registered it will get the newest available firmware from the repository based on model and revision.
Frontend allows to assign specific firmware to be rolled out.
Rollouts allow a fine-grained assignment of firmwares to devices. The reported device model and revision is combined with the manually set feed value on a device to determine a matching rollout.
The feed is meant to model either different environments (like: dev, qa, live) or update channels (like. candidate, fast, stable).
Device can be pinned to its current firmware.
While an update is running, the update logs are captured and visualized in the frontend.
Code is formatted using different tools
- black and isort for
*.py
- biomejs for
*.js
,*.json
- prettier for
*.html
,*.md
,*.yml
,*.yaml
Code is linted using different tools as well
- flake8 for
*.py
- biomejs for
*.js
Best to have pre-commit install git hooks that run all those tools before a commit:
poetry run pre-commit install
To manually apply the hooks to all files use:
pre-commit run --all-files
Tests are implemented using pytest. To run all tests
poetry run pytest