1 |
On Tuesday 23 September 2008, Alan McKinnon wrote: |
2 |
> On Tuesday 23 September 2008 17:32:51 Anthony Metcalf wrote: |
3 |
> > Hi, |
4 |
> > |
5 |
> > This is a theoretical question, and a very simplified example of |
6 |
> > what I'm thinking, but it serves to get the idea across.... |
7 |
> > |
8 |
> > Suppose I am planning multiple Gentoo servers, I will want them all |
9 |
> > based on the "Hardened" profile (they are servers after all!) but I will |
10 |
> > also want them all to have the ipv6 use flag set, since my internal |
11 |
> > network is completely ipv6. |
12 |
> > |
13 |
> > Which is better, have a standard make.conf, with USE="ipv6" and copy |
14 |
> > that around, or create my own profile? |
15 |
> |
16 |
> it's 6 and half a dozen really, both methods have the same effect. You have |
17 |
> to weigh up the hassle of creating the profile and the ease of using it |
18 |
> with the ease of modifying make.conf and the hassle of copying it |
19 |
> everywhere. Plus, with just a make.conf, you can't extend your system set. |
20 |
> It's your call really there is not a OneTrueRightWay(tm) |
21 |
> |
22 |
> > I assume that I could copy the hardened profile, change a couple of |
23 |
> > files, and then re-link make.profile. |
24 |
> |
25 |
> You don't copy the profile as such, you inherit from it. Create a new |
26 |
> directory somewhere, and put a file in it called "parent" which points to |
27 |
> the hardened profile that's your base. Put your mods in correctly named |
28 |
> files in that directory and point make.profile to it. |
29 |
> |
30 |
> This is all documented *somewhere* but I once spent 10 minutes looking |
31 |
> through the existing profile directories and it was stunningly obvious how |
32 |
> it all worked. |
33 |
> |
34 |
> > 1) Would changes be lost on rysnc, since my new folder isn't in the |
35 |
> > tree I'm syncing with? Is there a way around that? |
36 |
> |
37 |
> If you put it in the portage directory and don't take special steps, then |
38 |
> your profile will be nuked. But --sync is just an rsync operation, and |
39 |
> rsync's man page is every longer than ls's :-) with options for every |
40 |
> imaginable thing. You should be able to figure out the options to exclude |
41 |
> your custome profile with ease |
42 |
> |
43 |
> > The advantage I see over the copy-the-make.conf situation, is that I |
44 |
> > can change the use flags once, and they are copied for all servers at |
45 |
> > the next sync (all servers would obviously sync to a central box), |
46 |
> > whilst still being able to keep other things (CFLAGS? IF servers have |
47 |
> > different processors etc) different for different servers.... |
48 |
> |
49 |
> You could even set up a mini- trimmed-down sync server. Put your master |
50 |
> copies of stuff there, take steps so that portage doesn't nuke things, and |
51 |
> set up a cron to sync once a day. Tell your machines to get their portage |
52 |
> tree from this server, not gentoo.org somewhere and let rip. Also put a |
53 |
> proxy on that sync server of yours so distfile downloads only happen once. |
54 |
> There's many ways to do this - squid is obvious but I believe portage can |
55 |
> do something similar (which I have not used myself) |
56 |
|
57 |
you can even put the compiling on one server and let the others download and |
58 |
install the packets. AFAIR BINHOST is the thing to google for. |