Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Automatic build packages
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
luckylinux
n00b
n00b


Joined: 17 Mar 2012
Posts: 45

PostPosted: Tue Apr 17, 2018 5:15 pm    Post subject: Automatic build packages Reply with quote

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
View user's profile Send private message
audiodef
Watchman
Watchman


Joined: 06 Jul 2005
Posts: 6316
Location: /usr/lib64/lv2

PostPosted: Tue Apr 17, 2018 5:25 pm    Post subject: Reply with quote

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.
_________________
Gentoo Studio: A Gentoo-based, professional digital audio workstation OS.
Back to top
View user's profile Send private message
luckylinux
n00b
n00b


Joined: 17 Mar 2012
Posts: 45

PostPosted: Tue Apr 17, 2018 5:34 pm    Post subject: Reply with quote

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
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43755
Location: 56N 3W

PostPosted: Tue Apr 17, 2018 5:35 pm    Post subject: Reply with quote

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
View user's profile Send private message
luckylinux
n00b
n00b


Joined: 17 Mar 2012
Posts: 45

PostPosted: Tue Apr 17, 2018 6:43 pm    Post subject: Reply with quote

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
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43755
Location: 56N 3W

PostPosted: Tue Apr 17, 2018 7:23 pm    Post subject: Reply with quote

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
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum