Re: [CentOS] how to 'yum update' in a %post

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Tom Brown wrote:


you need to run this without the --nochroot option, there is no yum
included in the installer system, and the only yum you will get working
is the one inside the chroot.


OK thanks makes sense - however is there anyway to make some things run with --nochroot and others with it? Just that there is other things allready going on that need the --nochroot

You can have both:

%post --nochroot
<Some stuff>

%post --interpreter /bin/sh
<More stuff>

This is what the end of my kickstart file looks like:

%post --nochroot --interpreter /bin/sh
cp /tmp/hostname /mnt/sysimage/root/.

%post --interpreter /bin/bash
mount 192.168.100.1:/exports/centos /mnt
cd /mnt
./scripts/post_install.sh
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux