View previous topic :: View next topic |
Author |
Message |
luckylinux n00b
Joined: 17 Mar 2012 Posts: 48
|
Posted: Tue Apr 17, 2018 5:15 pm Post subject: Automatic build packages |
|
|
Hello,
I am wondering whether there is some tutorial or documentation for this.
I am trying to setup an automatic build host in order to prepare and update all binary packages for a given set of profile, CHOST and USE flags.
I read Funtoo uses Metro and Gentoo uses Catalyst to automatically build stages.
I would like to know if there is something similar but for automatically building the whole system and then serve the binary packages via web server to client machines.
The closes I was able to find was Flameeyes' Tindebox but unfortunately that project was abandoned. And the "Tinderbox" articles on the wiki are not really helping.
Does anybody have a link to a specific tutorial ?
I assume setting up a cron job and then email the result would be not the proper way to do this ... |
|
Back to top |
|
|
audiodef Watchman
Joined: 06 Jul 2005 Posts: 6656 Location: The soundosphere
|
Posted: Tue Apr 17, 2018 5:25 pm Post subject: |
|
|
I kind of doubt a single package exists to do *all* of that. As a catalyst user, I know you can use it to build binpackages. I run catalyst via cron weekly, so I know you can have catalyst build your binaries in a cron script, with the same script cp/mv'ing the binaries to an accessible location on your web server. You'll then need something else if you need an auto-deploy/install system. Maybe an update script distributed to the machines you maintain to fetch and install the binaries? Also, I think portage can be configured to use binaries, but as I don't do that I don't have advice about it. _________________ decibel Linux: https://decibellinux.org
Github: https://github.com/Gentoo-Music-and-Audio-Technology
Facebook: https://www.facebook.com/decibellinux
Discord: https://discord.gg/73XV24dNPN |
|
Back to top |
|
|
luckylinux n00b
Joined: 17 Mar 2012 Posts: 48
|
Posted: Tue Apr 17, 2018 5:34 pm Post subject: |
|
|
Thank you for your very quick reply audiodef.
I already have clients configured to fetch binary packages from the host.
I am putting in place also a system to keep in sync the content of /etc/portage and possibly also the world file.
However what I am still missing is how to automate the build process on the host / server.
Is there any guide on how to setup catalyst and would it be in any way different than just invoking a cron script of "emerge -uDn --with-bdeps=y --backtrack=1000 --autounmask-keep-masks=y" or something like that ? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54663 Location: 56N 3W
|
Posted: Tue Apr 17, 2018 5:35 pm Post subject: |
|
|
luckylinux,
What is "all binary packages"?
Every version of every ebuild in the tree available for your arch or just a subset of interest?
What are your build constraints?
I guess you don't want to build everything every time ... only if its changed?
Be aware that some packages may not be distributed in binary form too. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
luckylinux n00b
Joined: 17 Mar 2012 Posts: 48
|
Posted: Tue Apr 17, 2018 6:43 pm Post subject: |
|
|
Thank you for your question, NeddySeagoon.
Indeed my question was a bit ambiguous. I meant basically given a world file, to create binary packages whenever a new version is released, USE flags change, gcc version changes and so on. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54663 Location: 56N 3W
|
Posted: Tue Apr 17, 2018 7:23 pm Post subject: |
|
|
luckylinux,
Code: | emerge --sync
emerge -uDUav @world --with-bdeps=y --backtrack=50 --jobs=2 --keep-going | is how I normally update on an AMD/Intel system.
FEATURES has buildpkg, so binaries are always saved
--autounmask* is usually incorrect in that if its needed, you really need to see what it wants to do.
e.g. Unless you are doing upstream development, you should not be using live ebuilds.
If @world contains a mix of stable and testing packages, you will get issues.
That's the server end. The binaries go into /usr/portage/packages by default.
Wherever you put them, you need to share that with the clients.
On the clients, you need a make.conf entry like Code: | PORTAGE_BINHOST="http://bloodnoc.org/~roy/BINHOSTS/gcc-7.x/armv8a" | if the server is remote.
Other protocols work too. On your LAN, you can use NFS.
That particular BINHOST is for a 64 bit Raspberry Pi. Feel free to look around and even use it if its useful.
Now the client can use the -g or -G option to emerge as in Code: | Pi3_~arm64 /usr/portage # emerge -uDUgav @world --with-bdeps=y --keep-going --backtrack=50 |
It helps if all the portage repos are in sync too. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
|