Export docker image into tar file directly from registry API
Project description
docker-export
Export Docker Images to a single .tar
without docker
: Using Python
and the registry's API.
Usages
Installation
docker-export
is a Python3 software. You are advised to use it in a
virtual environment to avoid installing software dependencies on your
system.
python3 -m venv ./env # creates a virtual python environment in ./env folder
./env/bin/pip install -U pip # upgrade pip (package manager). recommended
./env/bin/pip install -U docker-export[all] # install/upgrade docker-export inside virtualenv
# direct access to in-virtualenv docker-export binary, without shell-attachment
./env/bin/docker-export --help
# alias or link it for convenience
sudo ln -s $(pwd)/env/bin/docker-export /usr/local/bin/
# alternatively, attach virtualenv to shell
source env/bin/activate
docker-export --help
deactivate # unloads virtualenv from shell
Command line
docker-export --platform linux/arm/v7 ghcr.io/kiwix/kiwix-tools:3.0.0 kiwix-tools.tar
Python module
import pathlib
from docker_export import Platform, Image, export
export(
image=Image.parse("kiwix/kiwix-tools:3.3.0"),
platform=Platform.auto(),
to=pathlib.Path("kiwix-tools.tar"),
)
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
docker_export-0.2.tar.gz
(21.7 kB
view details)
Built Distribution
File details
Details for the file docker_export-0.2.tar.gz
.
File metadata
- Download URL: docker_export-0.2.tar.gz
- Upload date:
- Size: 21.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.27.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f6758b4081f112c54ddfd30e9a3f5d91c9cde4094ec32068929e65b345072bfa |
|
MD5 | 57dc4162ef910d365c8d148a56f04cbb |
|
BLAKE2b-256 | 50474952a681d1892409421e0c6fc73038c3f7031518b372c3ee1078098c39dd |
File details
Details for the file docker_export-0.2-py3-none-any.whl
.
File metadata
- Download URL: docker_export-0.2-py3-none-any.whl
- Upload date:
- Size: 21.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.27.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88d2e761e543cab2df256c23585c6a8d79c3e64da0a49e6d7158faddcde9b6bb |
|
MD5 | 8ffc0f081b5cd6edb4e90d1deac69356 |
|
BLAKE2b-256 | b7d478d954647d721c51413996ea06f0398680adf1ea785b3e9add2d87424d46 |