Debian packaging
This commit is contained in:
49
README.md
49
README.md
@@ -139,6 +139,55 @@ From then on, `sudo dnf upgrade` picks up new releases.
|
||||
- The RPM is built against this machine's libraries, so it installs on this
|
||||
Fedora release and newer.
|
||||
|
||||
### Distributing to Debian/Ubuntu (apt repo)
|
||||
|
||||
Debian-based machines get the app the same way, from an apt repo you host.
|
||||
`scripts/deb-publish.sh` builds the `.deb` here on Fedora and adds it to the
|
||||
repo in a directory you choose. It needs:
|
||||
|
||||
```bash
|
||||
sudo dnf install reprepro dpkg
|
||||
```
|
||||
|
||||
It signs with the same key as the dnf repo. If you haven't made that key yet,
|
||||
pass `--init-key` the first time. Either way, give the first run the address
|
||||
the directory will be served at:
|
||||
|
||||
```bash
|
||||
DEB_REPO_URL=https://deb.example.com/mtgc ./scripts/deb-publish.sh ~/deb-mtgc
|
||||
```
|
||||
|
||||
After that, publishing is just:
|
||||
|
||||
```bash
|
||||
./scripts/deb-publish.sh ~/deb-mtgc # or: npm run deb:publish -- ~/deb-mtgc
|
||||
```
|
||||
|
||||
Then, on each machine, add the repo once and install:
|
||||
|
||||
```bash
|
||||
sudo curl -fsSLo /etc/apt/sources.list.d/mtgc.sources https://deb.example.com/mtgc/mtgc.sources
|
||||
```
|
||||
|
||||
```bash
|
||||
sudo apt update && sudo apt install mtgc
|
||||
```
|
||||
|
||||
From then on, `sudo apt upgrade` picks up new releases.
|
||||
|
||||
- **Serve the whole directory.** It holds `pool/`, the signed `dists/`, the
|
||||
public key (`mtgc.asc`) and `mtgc.sources`, which carries the key inline so
|
||||
machines don't need a separate keyring step. `conf/` and `db/` are
|
||||
reprepro's own state; they're harmless to serve but aren't needed. The
|
||||
newest three versions are kept, so a bad release can be undone with
|
||||
`sudo apt install mtgc=<older version>`.
|
||||
- Versions are the same as the RPM's. A build published with `--allow-dirty`
|
||||
gets a `~dirty` suffix, which apt sorts below the clean build of the same
|
||||
version.
|
||||
- The `.deb` is built against this machine's libraries, so it needs a distro
|
||||
with at least this Fedora's glibc (2.43 on Fedora 44). Older Debian and
|
||||
Ubuntu releases can't install it.
|
||||
|
||||
### Distributing to Windows
|
||||
|
||||
The Windows installer is cross-built here on Linux and published to a plain
|
||||
|
||||
Reference in New Issue
Block a user