Bug 256681

Summary: localhost entry required in /etc/hosts
Product: [Retired] Fedora Hosted Projects Reporter: BJ Dierkes <wdierkes>
Component: mockAssignee: Clark Williams <williams>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: low Docs Contact:
Priority: medium    
Version: unspecifiedCC: dcantrell, derks, tis
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: 0.9.7-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-03-07 20:31:56 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch to create /etc/hosts with a localhost entry. none

Description BJ Dierkes 2007-08-27 15:13:36 UTC
Description of problem:

No /etc/hosts file created.


Version-Release number of selected component (if applicable):

0.7.2


How reproducible:

Perform anything that needs to 'init' a build root.


Steps to Reproduce:
1. mock -r<config> init

  
Actual results:

No /etc/hosts file created.


Expected results:

/etc/hosts file created, with atleast an entry for localhost.


Additional info:

This is a minor change, however certain build require localhost to resolve to
127.0.0.1.  For example, MySQL test suites run a MySQL instance running on
localhost.  If 'localhost' does not resolve (meaning, there is no entry in
/etc/hosts for it) then the test cases fail.

Comment 1 BJ Dierkes 2007-08-27 15:13:36 UTC
Created attachment 173761 [details]
Patch to create /etc/hosts with a localhost entry.

Comment 2 Tuomo Soini 2007-09-09 19:20:19 UTC
I'd suggest copying system /etc/hosts file into mock chroot instead of
generating new one.

Comment 3 Clark Williams 2008-03-07 20:31:56 UTC
the current version of mock creates a default hosts file with localhost entry.
If you want to use a copy of the system hosts file, you can create a chroot then
use the --copyin function to overwrite the default.