On 05/27/2011 11:34 PM, Christian Horn wrote:
> On Fri, May 27, 2011 at 01:21:14PM -0500, Owen Beckley wrote:
>>
>> I'm currently running cobbler 2.0.3 on CentOS 5.
>>
>> I was wondering if there is an automated way to have a repo included in
>> cobbler, but have it be disabled by default when it's listed in
>> /etc/yum.repos.d/cobbler-config.repo.
> 
> You could always
> - add it as usual
> - disable it in %post with a line of sed
> 
> The only downside I see is if you list packages in %packages that are 
> more current in your 'optional' repo they will be fetched from there.

Depending on how broad you want the "disabled-ness" to be, it's could even
easier than that.  Inside each repo directory, there is a file called
"config.repo" that is the template for what ends up Cobbler generated
cobbler-config.repo.  You can simply change the "enabled" line there and all
future deployments with that repo associated will have the repo available, but
not enabled by default.

I like to do this with the RPMForge repo since they provide good packages, but
sometimes conflict with what comes in the RHEL base OS.

/var/www/cobbler/repo_mirror/RPMForge-5-x86_64 # cat config.repo
[RPMForge-5-x86_64]
name=RPMForge-5-x86_64
baseurl=http://${server}/cobbler/repo_mirror/RPMForge-5-x86_64
enabled=0
priority=90
gpgcheck=0

-- 
/* Wes Hardin */
UNIX/Linux Systems Administrator, IT Engineering Support
Maxim Integrated Products: Innovation Delivered
_______________________________________________
cobbler mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/cobbler

Reply via email to