SepehrSabzPackage Mirrors
mirror online

rocky-mirror / dnf pull-through cache

This host mirrors dl.rockylinux.org — BaseOS, AppStream, extras, and CRB — across the currently supported Rocky Linux major releases. Point dnf/yum here to speed up installs and cut outbound bandwidth. The examples below use mirror.sepehrsabz.ir/rocky.

01 — REPO FILES

Point baseurl at the mirror, disable mirrorlist

Edit Rocky Linux's .repo files in /etc/yum.repos.d/ — comment out mirrorlist= and set baseurl= to the mirror instead.

/etc/yum.repos.d/rocky-baseos.repo
[baseos]
name = Rocky Linux $releasever - BaseOS
#mirrorlist = https://mirrors.rockylinux.org/mirrorlist?arch=$basearch&repo=BaseOS-$releasever
baseurl = https://mirror.sepehrsabz.ir/rocky/$releasever/BaseOS/$basearch/os/
gpgcheck = 1
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rockyofficial
/etc/yum.repos.d/rocky-appstream.repo
[appstream]
name = Rocky Linux $releasever - AppStream
#mirrorlist = https://mirrors.rockylinux.org/mirrorlist?arch=$basearch&repo=AppStream-$releasever
baseurl = https://mirror.sepehrsabz.ir/rocky/$releasever/AppStream/$basearch/os/
gpgcheck = 1
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rockyofficial
/etc/yum.repos.d/rocky-crb.repo
[crb]
name = Rocky Linux $releasever - CRB
#mirrorlist = https://mirrors.rockylinux.org/mirrorlist?arch=$basearch&repo=CRB-$releasever
baseurl = https://mirror.sepehrsabz.ir/rocky/$releasever/CRB/$basearch/os/
gpgcheck = 1
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rockyofficial

CRB (CodeReady Builder, formerly PowerTools on Rocky 8) is disabled by default — enable it with dnf config-manager --set-enabled crb if you need development headers or static libs from it.

02 — SUPPORTED RELEASES

What this mirror carries

VersionUpstream baseNotes
10RHEL 10Current major release
9RHEL 9Long-term maintained
8RHEL 8Maintained until EOL, check upstream

Rocky Linux tracks RHEL's own support lifecycle 1:1 — check wiki.rockylinux.org/rocky/version for exact end-of-life dates for each major version, since they follow Red Hat's published schedule rather than a Rocky-specific cadence.

03 — DOCKER / CI

Repoint inside a build

Dockerfile
FROM rockylinux:9
RUN sed -i 's|^mirrorlist|#mirrorlist|; s|^#baseurl=https://dl.rockylinux.org|baseurl=https://mirror.sepehrsabz.ir|' \
      /etc/yum.repos.d/rocky*.repo && \
    dnf makecache

The official Rocky Linux images already ship a commented-out baseurl= template pointing at dl.rockylinux.org — uncomment and repoint that line rather than adding a new one, to avoid duplicate repo IDs.

04 — VERIFY

Confirm dnf is pulling through the mirror

shell
dnf repolist -v | grep -i baseurl
curl -s https://mirror.sepehrsabz.ir/rocky/9/BaseOS/x86_64/os/repodata/repomd.xml -o /dev/null -w "%{http_code}\n"

# install something and time it
time sudo dnf install -y htop
CheckExpected result
dnf repolist -vShows mirror.sepehrsabz.ir as the baseurl
GET /repodata/repomd.xml200 — mirror is reachable
First install of a packageSlower — cache miss, fetched from upstream and stored
Repeat install elsewhere on the networkFast — served from local cache
05 — NOTES
Package integrity is unaffected. gpgcheck=1 still validates every package against the Rocky Linux signing key regardless of which mirror served the bytes — switching baseurl doesn't touch that chain.

Rocky Linux is a 1:1 binary-compatible rebuild of RHEL, governed by the Rocky Enterprise Software Foundation (RESF) — package versions and update timing track Red Hat's upstream releases closely. This mirror doesn't publish packages, only reads. If it's served over plain HTTP internally, that's fine for dnf — package signatures, not transport TLS, are what dnf actually trusts by default.