You are not logged in.

#1 2017-05-04 20:04:40

wulfspider
Member
From: Germany, Hesse, Darmstadt
Registered: 2015-05-05
Posts: 13

Rebuilding packages automatically after dependency update

Hi,

at the moment I am running Debian on my servers and I tried to build packages for it but it's too complicated and time expensive.

So I thought about installing Arch on my servers (because packaging with PKGBUILD is much more easier). At first on some less important VMs to test the stability and such things.

For this I also want to deploy my packages over an own package repository. My question is if there is way to rebuild my packages automatically whenever a dependency from the official
repositories got an update.

If it's needed I would also set up an own mirror of the official repositories.

Offline

#2 2017-05-04 20:53:41

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: Rebuilding packages automatically after dependency update

What do you mean by "rebuild automatically"? It would be trivial to write a script to check for updates and launch makepkg-based build scripts (e.g. via Bash+Pacman or Python+pyalpm). There are also Pacman wrappers that can build packages provided they have a way to access the PKGBUILD and related files.

To maintain a repo, write some script that check for updates, rebuilt packages and then update your repo with repo-add (or repo-add_and_sign for batch signing, if you want sigs).


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#3 2017-05-04 21:14:39

wulfspider
Member
From: Germany, Hesse, Darmstadt
Registered: 2015-05-05
Posts: 13

Re: Rebuilding packages automatically after dependency update

What do you mean by "rebuild automatically"?

Let's say there was an update for openssl. Of course I don't want to rebuild the packages which don't use openssl because it wouldn't make any sense, but for example nginx. I would like to have something which detects that there was an update for Openssl, calls makepkg on my nginx pkgbuild and put the new version into the repository.

Last edited by wulfspider (2017-05-04 21:19:52)

Offline

#4 2017-05-04 22:01:13

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: Rebuilding packages automatically after dependency update

So use pyalpm to calculate dependency graphs for your custom packages and then auto-rebuild whenever there is a relevant change. You could run the script manually, on a timer, or using inotify events from the sync database.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

Board footer

Powered by FluxBB