| Summary: | Simplified lua postinstall scriplet for spec file | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Sergey Romanov <bugzilla.sero> | ||||
| Component: | bash | Assignee: | Roman Rakus <rrakus> | ||||
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
| Severity: | low | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | rawhide | CC: | maxamillion, rrakus, tsmetana, valdis.kletnieks | ||||
| Target Milestone: | --- | Keywords: | Reopened | ||||
| Target Release: | --- | ||||||
| Hardware: | All | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2011-11-10 14:31:52 UTC | Type: | --- | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Attachments: |
|
||||||
Thanks for the patch. I've applied it in bash-4.2.10-6.fc17 After upgrading to the latest bash rpm in rawhide yesterday, my /etc/shells ended up with just this in it, looks like the RPM script is eating it: /sbin/nologin /bin/tcsh /bin/csh Seems to be a problem with both F16 and Rawhide bash RPMs. # cat /etc/shells /sbin/nologin /bin/tcsh /bin/csh /bin/bash # rpm -Uvh --force ./bash-4.2.10-4.fc16.x86_64.rpm warning: ./bash-4.2.10-4.fc16.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID a82ba4b7: NOKEY Preparing... ########################################### [100%] 1:bash ########################################### [100%] # cat /etc/shells /sbin/nologin /bin/tcsh /bin/csh # echo /bin/bash >> /etc/shells # rpm -Uvh bash-4.2.10-6.fc17.x86_64.rpm Preparing... ########################################### [100%] 1:bash ########################################### [100%] # cat /etc/shells /sbin/nologin /bin/tcsh /bin/csh # echo /bin/bash >> /etc/shells Valdis thanks for the quick info. It's a problem Sergey mentioned - new line at last line. /me has to learn lua a bit more. ok, the problem is elsewhere. rpm calls post script first and then postun I will create new bug for this issue. See bug #752827 |
Created attachment 524450 [details] simplified postinstall scriplet for spec file I somewhat simplified the %post scriplet for bash package. Would you please consider to apply the attached patch? It makes no provisions for /etc/shells not ending with newline character, but neither does the scriplet presently in spec file, nor do %post scriplets from other shell packages. The stance such scriplets usually use is something like shell=/path/to/shell shells=/etc/shells grep -qs ^$shell$ $shells||echo $shell>>$shells Anyway, the check for the newline at last line of file is trivial to add in lua. Tell if you need that and I'll update the patch.