API library for Aptly.
Project description
python3-cyberfusion-aptly-apicli
API library for Aptly.
Install
PyPI
Run the following command to install the package from PyPI:
pip3 install python3-cyberfusion-aptly-apicli
Generic
Run the following command to create a source distribution:
python3 setup.py sdist
Debian
Run the following commands to build a Debian package:
mk-build-deps -i -t 'apt -o Debug::pkgProblemResolver=yes --no-install-recommends -y'
dpkg-buildpackage -us -uc
Configure
Config file options
- Section
aptly-api
, keyserverurl
- Section
aptly-api
, keyusername
(optional) - Section
aptly-api
, keyapikey
(optional)
Class options
config_file_path
. Non-default config file path.
Usage
Example
from cyberfusion.AptlyApiCli import AptlyApiRequest
r = AptlyApiRequest()
# Upload temporary file
endpoint = "/api/files/aptly-0.9"
with open("aptly_0.9~dev+217+ge5d646c_i386.deb", "rb") as f:
r.POST(endpoint, data={}, files={"file": f})
print(r.execute())
# Add package
endpoint = "/api/repos/repo1/file/aptly-0.9"
r = AptlyApiRequest()
r.POST(endpoint, data={})
print(r.execute())
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Close
Hashes for python3-cyberfusion-aptly-apicli-1.0.2.2.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 102db1831761bedddaeaf9e011dd685f0132d7af366c1776e96ba8ec72e6cea8 |
|
MD5 | 935c51f05603a1fbfddb8f5a22be98c3 |
|
BLAKE2b-256 | 4f396a53078cf30250729356740f663100713416227e3d0a0253992f4762a659 |