Bug 213033 - %pre merges with %post
Summary: %pre merges with %post
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Provisioning (Show other bugs)
(Show other bugs)
Version: unspecified
Hardware: All Linux
medium
medium
Target Milestone: ---
Assignee: Jan Pazdziora
QA Contact: Steve Salevan
URL:
Whiteboard:
Keywords:
Depends On:
Blocks: 248643
TreeView+ depends on / blocked
 
Reported: 2006-10-30 16:59 UTC by Matthew Davis
Modified: 2008-04-02 21:06 UTC (History)
1 user (show)

Fixed In Version: sat510
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-04-02 21:06:28 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description Matthew Davis 2006-10-30 16:59:40 UTC
Description of problem:

Using the following %pre script example, weird things happen with the kickstart.

- start -
cat > /tmp/a <<EOF
a
b
c
d
EOF
- end -

With the above script included in a kickstart profile as a %pre script,  The
kickstart file looks something like this:

%packages --resolvedeps

@ Base


%pre
cat > /tmp/a < /tmp/ssl-key-1 <<'EOF'
Certificate:
    Data:
        Version: 3 (0x2)
        Serial Number: 0 (0x0)
        Signature Algorithm: sha1WithRSAEncryption
.....
EOF
# ssl-key1
cat /tmp/ssl-key-* > /usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT
perl -npe 's/RHNS-CA-CERT/RHN-ORG-TRUSTED-SSL-CERT/g' -i /etc/sysconfig/rhn/*


And there is no %post section.


Version-Release number of selected component (if applicable):
rhns-4.1.0-89.rhel4 

How reproducible:
ever time

Steps to Reproduce:
1. Create kickstart profile
2. Create a %pre using hte script mentioned above
3.
  
Actual results:
Weirdness, and no %post section

Expected results:
See seperate %post & %pre sections

Additional info:
A work-around is to add a space between << & EOF so the line would be

cat > /tmp/a << EOF

Comment 1 Red Hat Bugzilla 2007-04-12 01:35:22 UTC
User bnackash@redhat.com's account has been closed

Comment 2 Jan Pazdziora 2007-10-09 09:10:08 UTC
I've just tried this on rhns-5.1.0-9 and both the %pre and %post scripts are
shown as expected. So I assume that with the numerous changes to the kickstart
generation code, this problem got resolved.

As such, moving to ON_QA.

Taking from Mike's plate and reassigning to myself for possible kickbacks.

Comment 3 Steve Salevan 2007-10-16 16:21:32 UTC
On the latest ISO build, 510-15, including the test script as a %pre script does
not cause the funky behavior originally reported.  Thus, it looks like this bug
is now VERIFIED.

Comment 5 Steve Salevan 2008-03-20 17:49:54 UTC
Looks good on Stage Satellite, moving to RELEASE_PENDING.

Comment 6 Brandon Perkins 2008-04-02 21:06:28 UTC
UI Enhancements for 5.1 Sat GA so Closed for Current Release.


Note You need to log in before you can comment on or make changes to this bug.