How to enter values during the rpm -i and use them in the postinstall process

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

 



All,

I know I have repeated my posts, but I am still trying to find the answers.
Please help.

1. I understand that I can use prefix to define the installation location. I
have done that in my spec file. Thanks.

2. I would like to do the following on top of using --prefix for locating
the installation directory,

"rpm -i software_a.rpm STRING1 STRING2"

STRING1 and STRING2 are just string variables.

3. "Could you please explain your need more clearly and reasoning behind it.
Remember rpm installs are meant to be non-interactive and can be done via
the api/depsolver bypassing the command line."

I would like to be able to doing something in the postinstall section of the
spec file such as:

"echo $STRING1"
"echo $STRING2"

Of course, I will do more than just echo, but having the abilities to do
echo meaning I can use those strings however I want during the postinstall
process. Essentially, STRING1 can be a servername, and the postinstall
section of the spec file needs to process this servername or start processes
with this string.

4. "James' reply covered this thoroughly please reread, currently passing
parameters to scriptlets is unspupported.  Bleeding edge work is being done
one this but you can not do this at the moment with any released version of
rpm."

So, nobody actually pass parameters, values while doing "rpm -i"??? How does
one able to do what I want to do in their installation? I am sure that it is
not uncommon to do it, am i right?

5. If I cannot pass the values from the "rpm -i" command, then how can i
assign STRING1 and STRING2 during the installation? Prompts in postinstall
part of the spec file?

Thanks and please advice.

Barry



_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-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