Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1198307 - Cannot build foreman-selinux on RHEL 7.1
Cannot build foreman-selinux on RHEL 7.1
Status: CLOSED ERRATA
Product: Red Hat Satellite 6
Classification: Red Hat
Component: SELinux (Show other bugs)
6.1.0
Unspecified Unspecified
unspecified Severity high (vote)
: Beta
: Unused
Assigned To: Lukas Zapletal
Corey Welton
: Triaged
Depends On: 1202695
Blocks:
  Show dependency treegraph
 
Reported: 2015-03-03 13:50 EST by Jason Montleon
Modified: 2017-02-23 15:24 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-08-12 01:28:36 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1592 normal SHIPPED_LIVE Important: Red Hat Satellite 6.1.1 on RHEL 6 2015-08-12 05:04:35 EDT

  None (edit)
Description Jason Montleon 2015-03-03 13:50:16 EST
Description of problem:
Error is:
+ make NAME=targeted -f /usr/share/selinux/devel/Makefile DISTRO=rhel7
Compiling targeted foreman module
foreman.te:394: Warning: miscfiles_read_certs() has been deprecated, please use miscfiles_read_generic_certs() instead.
/usr/bin/checkmodule:  loading policy configuration from tmp/foreman.tmp
foreman.te":148:ERROR 'unknown type httpd_foreman_script_t' at token ';' on line 4713:
#line 148
	typeattribute httpd_foreman_script_t syslog_client_type;
/usr/bin/checkmodule:  error(s) encountered while parsing configuration
make: *** [tmp/foreman.mod] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.yn94cK (%build)
RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.yn94cK (%build)
Child returncode was: 1
EXCEPTION: Command failed. See logs for output.
 # ['bash', '--login', '-c', 'rpmbuild -bb --target noarch --nodeps builddir/build/SPECS/foreman-selinux.spec']
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/mockbuild/trace_decorator.py", line 70, in trace
    result = func(*args, **kw)
  File "/usr/lib/python2.6/site-packages/mockbuild/util.py", line 345, in do
    raise mockbuild.exception.Error, ("Command failed. See logs for output.\n # %s" % (command,), child.returncode)
Error: Command failed. See logs for output.
 # ['bash', '--login', '-c', 'rpmbuild -bb --target noarch --nodeps builddir/build/SPECS/foreman-selinux.spec']
LEAVE do --> EXCEPTION RAISED

Version-Release number of selected component (if applicable):
foreman-selinux-1.7.2.9-1.el7sat

foreman-selinux-1.7.2.9-1.el6_6sat built OK.
Comment 2 Lukas Zapletal 2015-03-17 04:53:20 EDT
Regression for RHEL 7.1, reported as https://bugzilla.redhat.com/show_bug.cgi?id=1202695
Comment 3 Lukas Zapletal 2015-03-17 04:58:17 EDT
Ugly workaround is to comment out:

logging_send_syslog_msg(httpd_foreman_script_t)

Because this is unused in the default configuration I think.
Comment 4 Jason Montleon 2015-03-19 15:59:28 EDT
This is breaking anywhere httpd_foreman_script_t is. Can I comment out all 7 lines without breaking the policy?
Comment 6 Jason Montleon 2015-03-20 08:54:53 EDT
This is the new one:
Compiling targeted foreman module
foreman.te:376: Warning: miscfiles_read_certs() has been deprecated, please use miscfiles_read_generic_certs() instead.
/usr/bin/checkmodule:  loading policy configuration from tmp/foreman.tmp
foreman.te":196:ERROR 'unknown type httpd_foreman_script_exec_t' at token ';' on line 5817:
#line 196
	allow passenger_t httpd_foreman_script_exec_t:dir { getattr search open };
/usr/bin/checkmodule:  error(s) encountered while parsing configuration
make: *** [tmp/foreman.mod] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.vcRTxX (%build)
RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.vcRTxX (%build)
Child returncode was: 1
EXCEPTION: Command failed. See logs for output.
 # ['bash', '--login', '-c', 'rpmbuild -bb --target noarch --nodeps builddir/build/SPECS/foreman-selinux.spec']
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/mockbuild/trace_decorator.py", line 70, in trace
    result = func(*args, **kw)
  File "/usr/lib/python2.6/site-packages/mockbuild/util.py", line 345, in do
    raise mockbuild.exception.Error, ("Command failed. See logs for output.\n # %s" % (command,), child.returncode)
Error: Command failed. See logs for output.
 # ['bash', '--login', '-c', 'rpmbuild -bb --target noarch --nodeps builddir/build/SPECS/foreman-selinux.spec']
LEAVE do --> EXCEPTION RAISED
Comment 10 Mike McCune 2015-03-20 17:46:17 EDT
moving back to MODIFIED as we had to roll this back for :

https://bugzilla.redhat.com/show_bug.cgi?id=1204301
Comment 11 Lukas Zapletal 2015-03-23 04:48:25 EDT
Unfortunately upstream fix was not yet merged and properly tested. There was an issue.

Jason this line should not have been deleted:

manage_files_pattern(passenger_t, foreman_log_t , foreman_log_t)
Comment 13 Mike McCune 2015-03-26 00:09:01 EDT
QE:

I don't think there is anything to test here, more of a dev task.

If you want you can verify that your systems get:

foreman-selinux-1.7.2.13-1

nothing todo beyond that.
Comment 14 Corey Welton 2015-03-26 14:24:45 EDT
Verified in Satellite-6.1.0-RHEL-7-20150324.0
Comment 15 Bryan Kearney 2015-08-11 09:32:41 EDT
This bug is slated to be released with Satellite 6.1.
Comment 16 errata-xmlrpc 2015-08-12 01:28:36 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2015:1592

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