https://github.com/endlessm/ostree-upload-server
Web service to import static deltas to an ostree repository
https://github.com/endlessm/ostree-upload-server
Last synced: 12 months ago
JSON representation
Web service to import static deltas to an ostree repository
- Host: GitHub
- URL: https://github.com/endlessm/ostree-upload-server
- Owner: endlessm
- Created: 2017-04-19T18:39:48.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2022-10-26T15:47:59.000Z (over 3 years ago)
- Last Synced: 2025-03-26T15:42:53.664Z (about 1 year ago)
- Language: Python
- Size: 196 KB
- Stars: 5
- Watchers: 23
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.txt
Awesome Lists containing this project
README
Build a docker image:
# docker build -t ostree-upload-server .
Check configuration in ostree-upload-server.conf
Launch container:
# sudo docker run -it --rm \
-p 127.0.0.1:5000:5000 \
-v /tmp/ostree-upload-server.conf:/opt/ostree-upload-server/ostree-upload-server.conf \
-v /tmp/eos-flatpak-keyring.gpg:/gpg/trusted-keys.gpg \
-v /tmp/repo:/repo \
ostree-upload-server
Launch container with test configuration:
# sudo docker run -it --rm \
-p 127.0.0.1:5000:5000 \
-v $(pwd)/test/ostree-upload-server.conf:/opt/ostree-upload-server/ostree-upload-server.conf \
-v $(pwd)/test/gpg:/opt/ostree-upload-server/gpg \
ostree-upload-server
To upload a file with curl:
# curl -F "file=@/path/to/app.bundle" -u user:secret http://localhost:5000/upload
Note the task ID in the returned JSON. Now poll the task:
# curl -u user:secret "http://localhost:5000/upload?task=$TASK_ID"
Note the state in the returned JSON. When the state is COMPLETED or FAILED,
the task has completed.