# AlmaLinux mirror (pkg.shecan.ir)

> Mirror of repo.almalinux.org for dnf and yum on AlmaLinux 9 and 10.

- Upstream: repo.almalinux.org
- Mirror URL: <https://mirror-almalinux.pkg.shecan.ir/>
- Clients: dnf, yum
- Service status: <https://pkg.shecan.ir/status.json> (key `almalinux`; up/down, refreshed every minute)
- Guide (Persian, HTML): <https://pkg.shecan.ir/mirrors/almalinux/>
- JSON: <https://pkg.shecan.ir/api/v1/mirrors/almalinux.json>
- Integrity comparison with the official source (audit.shecan.ir, also run by Shecan, open source; group `almalinux`, mirror `shecan`): <https://audit.shecan.ir/#almalinux>

## Limitations

- On AlmaLinux 8 and newer, yum is dnf; both commands work.
- On AlmaLinux 10 only the repository paths (BaseOS, AppStream) were verified on the mirror.

## Setup

Every block below is the exact text of the Persian guide. Unless marked otherwise it is run against the live mirror in a disposable container on every catalog change; "checked by hand" blocks cannot run in a container. Change a machine only with its owner's permission: back up existing configuration first, merge into existing files instead of overwriting them, and keep the "Undo" step at hand.

### dnf, yum: persistent (user- or system-wide configuration)

Back up first (linux)

```sh
sudo mkdir -p /root/yum.repos.d.bak && sudo cp /etc/yum.repos.d/almalinux*.repo /root/yum.repos.d.bak/
```

Run (linux)

```sh
sudo sed -i 's/^mirrorlist=/#mirrorlist=/; s|^# baseurl=https://repo.almalinux.org/almalinux|baseurl=https://mirror-almalinux.pkg.shecan.ir|' /etc/yum.repos.d/almalinux*.repo
```

Run (linux)

```sh
sudo dnf makecache
sudo yum install -y jq
```

Undo / restore the default (linux)

```sh
sudo cp /root/yum.repos.d.bak/almalinux*.repo /etc/yum.repos.d/
```
