Bug 805449

Summary: rhncfg do not honour server_name if rhncfg-manager.conf is customized
Product: [Community] Spacewalk Reporter: Miroslav Suchý <msuchy>
Component: ClientsAssignee: Milan Zázrivec <mzazrivec>
Status: CLOSED CURRENTRELEASE QA Contact: Red Hat Satellite QA List <satqe-list>
Severity: low Docs Contact:
Priority: unspecified    
Version: 1.7CC: jpazdziora
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-11-01 16:19:23 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:
Bug Depends On:    
Bug Blocks: 871344    

Comment 3 Miroslav Suchý 2012-03-24 06:15:41 UTC
Substitution in local_config.

In this code the situation looks as follows:

# server_name = "enter.your.server.url.here"
# print "Using server name", server_name
Using server name enter.your.server.url.here
# local_config.init(self.config_section, defaults=up2date_cfg,
server_name=server_name)
so local_config get that "enter.your.server.url.here" as server_name
but the trick is that rest of that code do not use server_name, but server_url
and local_config get value of server_url from /etc/sysconfig/rhn/rhncfg-manager.conf, which by default is:
# server_url = https://%(server_name)s%(server_handler)s
where %() is macro which is expanded. So string printed in "Using server name" match with value later stored in server_url.
But in this specific case, the value in config file is:
# server_url = https://real.machine.redhat.com/CONFIG-MANAGEMENT-TOOL
and as there are no macros, no substitution happens and rest of the code use different url and hostname, then what is originally printed in "Using server name".

Comment 4 Milan Zázrivec 2012-05-11 14:24:18 UTC
spacewalk.git master: ba948a252975df3ec16ca13f0d51f02cceb7d89a

Comment 5 Jan Pazdziora 2012-10-30 19:24:07 UTC
Moving ON_QA. Packages that address this bugzilla should now be available in yum repos at http://yum.spacewalkproject.org/nightly/

Comment 6 Jan Pazdziora 2012-11-01 16:19:23 UTC
Spacewalk 1.8 has been released: https://fedorahosted.org/spacewalk/wiki/ReleaseNotes18