Skip to content

Arch Package Registry

HoyoShip has a Arch Linux package registry, which can act as a fully working Arch linux mirror and connected directly in /etc/pacman.conf. HoyoShip automatically creates pacman database for packages in user/organization space when a new Arch package is uploaded.

When uploading the package to HoyoShip, you have to prepare package file with the .pkg.tar.zst extension. You can use curl or any other HTTP client, HoyoShip supports multiple authentication schemes. The upload command will create 3 files: package, signature and desc file for the pacman database (which will be created automatically on request).

The following command will upload arch package and related signature to HoyoShip with basic authentication:

Terminal window
curl -X PUT \
https://{domain}/api/packages/{owner}/arch/{group} \
--user your_username:your_token_or_password \
--header "Content-Type: application/octet-stream" \
--data-binary '@/path/to/package/file/package-1-1-x86_64.pkg.tar.zst'
PlaceholderDescription
ownerThe owner of the package
groupRepository, e.g. os, extras .

First, you need to update your pacman configuration, adding following lines :

[{owner}.{group}.{domain}]
SigLevel = Required
Server = https://{domain}/api/packages/{owner}/arch/{group}/{architecture}

You can also copy content from the HoyoShip package page.

PlaceholderDescription
ownerThe owner of the package
groupRepository, e.g. os, extras
architectureSystem architecture, such as x86_64, aarch64

Then, import the server’s public key.

Terminal window
# Download the public key from the remote server.
wget -O sign.gpg https://{domain}/api/packages/{owner}/arch/repository.key
# Import the public key for pacman.
pacman-key --add sign.gpg
# Trust the certificate with the specified email
pacman-key --lsign-key '{owner}@noreply.{domain}'
PlaceholderDescription
domainYour HoyoShip domain, such as hoyoship.example.com.
ownerThe owner of the package

Finally, you can run pacman sync command (with -y flag to load connected database file), to install your package:

Terminal window
pacman -Sy {package}

The DELETE method will remove specific package version, and all package files related to that version:

Terminal window
curl -X DELETE \
https://{domain}/api/packages/{owner}/arch/{group}/{package}/{version}/{arch} \
--user your_username:your_token_or_password
PlaceholderDescription
ownerThe owner of the package
groupRepository, e.g. os, extras
packagePackage name
versionPackage version
archPackage arch

Any pacman compatible package manager or AUR-helper can be used to install packages from HoyoShip (yay, paru, pikaur, aura). Also, any HTTP client can be used to execute get/push/remove operations (curl, postman, thunder-client).