Interactive Docker package downloader and installer for Linux distributions supported by Docker's official repository.
doffline.sh reads Docker's official Linux package index, finds the latest package versions, compares them with locally installed versions, downloads selected packages, and configures Docker automatically.
| Type | Distributions | Format | Navigation |
|---|---|---|---|
| Debian-based | ubuntu, debian, raspbian | .deb |
release → channel → architecture |
| RPM-based | centos, fedora, rhel, rocky, alma, oracle, sles | .rpm |
release → architecture → channel |
| Static binaries | static | .tgz |
channel → architecture |
The script detects the repository layout automatically after you choose a distribution.
- Interactive distribution, release, channel, and architecture selection
- Live package discovery from Docker's official repository
- Latest Debian package version detection
- Installed versus recommended version comparison
- Color-coded package status:
- Green: installed version is current or newer
- Red: package is outdated or not installed
- Individual or batch package downloads
- Automatic SHA-256 checksum generation
- Download manifest generation
- Automatic package installation with
apt-get - Docker service enablement and startup
- Automatic
dockergroup creation and user configuration - Docker daemon and non-root access verification
- Automatic fallback from
curltowget - Detailed installation log and failure reporting
The default package set contains:
containerd.iodocker-cedocker-ce-clidocker-buildx-plugindocker-compose-plugin
You can also display and select every package family available in the chosen repository path.
Clone the repository:
git clone https://github.com/0xamirreza/Doffline.git
cd Doffline
chmod +x doffline.shRun the script as a normal user:
./doffline.shDo not run the complete script with sudo. It requests administrator privileges only when installation and system configuration are required.
For Ubuntu 22.04 on an AMD64 system, select:
ubuntu -> jammy -> stable -> amd64
For Fedora 42 on an AMD64 system, select:
fedora -> 42 -> x86_64 -> stable
For static binaries on AMD64, select:
static -> stable -> x86_64
The package table looks similar to:
Latest available package versions
# Package Installed version Recommended version Date
---- -------------------------------- ---------------------- ---------------------- ------------
1 containerd.io Not installed 2.2.6-1 2026-07-10
2 docker-ce Not installed 29.6.2-1 2026-07-16
3 docker-ce-cli Not installed 29.6.2-1 2026-07-16
4 docker-buildx-plugin Not installed 0.35.0-1 2026-06-24
5 docker-compose-plugin Not installed 5.3.1-1 2026-07-07
Enter a to download all displayed packages or enter package numbers separated by spaces:
Selection: 1 2 3
Downloaded files are stored beside the script in a directory named with the current date:
2026-07-21/
The directory contains:
2026-07-21/
|-- containerd.io_..._amd64.deb
|-- docker-buildx-plugin_..._amd64.deb
|-- docker-ce-cli_..._amd64.deb
|-- docker-ce_..._amd64.deb
|-- docker-compose-plugin_..._amd64.deb
|-- install.log
|-- manifest.tsv
`-- SHA256SUMS
RPM downloads use the same layout with .rpm files. Static downloads store .tgz archives in the same date directory.
Running the script again on the same day reuses the same date directory.
After all selected packages download successfully, the script automatically:
- Requests administrator authentication with
sudo - Installs the downloaded packages with
apt-get,dnf/yum, or extracts static binaries - Creates the
dockergroup if necessary - Adds the current user to the
dockergroup - Enables and starts the Docker service
- Verifies the Docker daemon
- Verifies Docker access through the
dockergroup
Full installation output is written to:
YYYY-MM-DD/install.log
After a successful installation, open a new login session or activate the group in the current terminal:
newgrp dockerVerify non-root Docker access:
docker version
docker run --rm hello-world- Linux
- Bash 4 or newer
curlorwgetdpkganddpkg-queryfor.debstatus checks and installation on Debian-based systemsrpm,dnf, oryumfor.rpmstatus checks and installation on RPM-based systemssudoapt-getfor automatic.debinstallationdnf,yum, orrpmfor automatic.rpminstallationsystemctlorservicesha256sumorshasumsgfor immediate group-access verification
Automatic package installation supports:
- Debian-based systems through
apt-get - RPM-based systems through
dnf,yum, orrpm - Static binaries through extraction to
/usr/local/binand optional systemd unit creation
Static installs do not include containerd packages from the repository; use .deb or .rpm packages when you need the full engine stack with package-manager dependencies.
The selected Docker packages are saved locally and can be transferred to another compatible system.
However, package-manager installs may download missing operating-system dependencies from configured repositories. For a fully disconnected installation, download all required dependency packages separately before moving the directory to the offline machine.
The target system must also match the selected:
- Distribution
- Release or codename
- CPU architecture
The script blocks automatic installation when the selected package architecture does not match the current system architecture.
Override Docker's default Linux repository:
DOFFLINE_BASE_URL="https://download.docker.com/linux" ./doffline.shOverride the HTTP User-Agent if a proxy or CDN rejects the default request:
DOFFLINE_USER_AGENT="Mozilla/5.0" ./doffline.shThe script uses HTTP/1.1 and automatically tries wget if curl fails.
The script automatically uses a browser-compatible User-Agent and falls back to wget. If both clients fail, check:
- Proxy or VPN rules
- Firewall restrictions
- DNS configuration
- System date and time
- Direct access to
download.docker.com
Open a new login session or run:
newgrp dockerThen verify:
docker infoReview the terminal error and the generated log:
cat YYYY-MM-DD/install.logDownloaded packages and successful partial downloads remain in the date directory.
From inside the output directory:
sha256sum --check SHA256SUMSMembership in the docker group grants root-equivalent access through the Docker daemon. Add only trusted users to this group.
./doffline.sh --helpAmirreza Sedighi A.K.A. 0XV
Repository: https://github.com/0xamirreza/Doffline