Re: scripts

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


On Tue, Jun 30, 2020 at 07:35:05AM -0400, Scott Andrews wrote:
> I have built some binary rpms that have scripts that need to run upon
> installation.  I am using the --root to install to an sdcard for a
> raspberry pi 4.  Does the scripts run in the proper context of the
> "new" root directory or will they run in the context of the "host".

It should be chrooted in the named directory:

  --root DIRECTORY

    Use the file system tree rooted at DIRECTORY for all operations.
    Note that this means the database within DIRECTORY will be used
    for dependency checks and any scriptlet(s) (e.g. %post if
    installing, or %prep if building, a package) will be run after
    a chroot(2) to DIRECTORY.

> I don't want to trash the host system

Depends on how you've populated the chroot environment.  Are those
files copies, or hard links?

I've hosed myself by improperly mounting /dev in the chroot
environment, and from within there, deleting things...

> _______________________________________________
> Rpm-list mailing list
> Rpm-list@xxxxxxxxxxxxx

Brian Reichert				<reichert@xxxxxxxxxxx>
BSD admin/developer at large	
Rpm-list mailing list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux