Bug 1302787 - Node web proxy configuration file is overwritten upon update
Summary: Node web proxy configuration file is overwritten upon update
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Cluster Version Operator
Version: 2.2.0
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: ---
: ---
Assignee: Timothy Williams
QA Contact: Anping Li
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-01-28 15:56 UTC by Timothy Williams
Modified: 2016-03-22 16:54 UTC (History)
4 users (show)

Fixed In Version: openshift-origin-node-proxy-1.26.2.1-1.el6op
Doc Type: Bug Fix
Doc Text:
Cause: The /etc/openshift/web-proxy-config.json configuration file for the node web proxy was not marked as a configuration file upon install. Consequence: New versions of the openshift-origin-node-proxy package would overwrite any changes to the /etc/openshift/web-proxy-config.json file with the original version of the file. Fix: The /etc/openshift/web-proxy-config.json file is now marked as a configuration file in the rpm spec. Result: The /etc/openshift/web-proxy-config.json file will no longer be overwritten when openshift-origin-node-proxy is updated.
Clone Of:
Environment:
Last Closed: 2016-03-22 16:54:09 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2016:0489 0 normal SHIPPED_LIVE Important: Red Hat OpenShift Enterprise 2.2.9 security, bug fix, and enhancement update 2016-03-22 20:49:04 UTC

Description Timothy Williams 2016-01-28 15:56:20 UTC
Description of problem:
The node web proxy's configuration file, /etc/openshift/web-proxy-config.json, is overwritten upon updating the rpm. 

The configuration file is not marked as a configuration file in the openshift-origin-node-proxy rpm spec file.

Comment 1 Timothy Williams 2016-01-28 15:57:26 UTC
This bug was resolved upstream in the following PR:

  https://github.com/openshift/origin-server/pull/6349

Comment 5 Anping Li 2016-02-24 05:37:09 UTC
The web-proxy-config.json was still overwritten. the web-proxy-config.json was pull in by openshift-origin-node-proxy. while this bug fixed in openshift-origin-node-util-1.38.6.1-1.el6op.

Comment 8 Anping Li 2016-02-29 05:30:06 UTC
There isn't web-proxy-config.json.rpmnew file after upgrade.

Comment 9 Timothy Williams 2016-02-29 16:23:01 UTC
This is working for me. You can see in the yum output that upgrading after modifying the web-proxy-config.json file results in an rpmnew file being created:

--------------------------------------------------------------
# yum localinstall /tmp/openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch.rpm 
Loaded plugins: priorities, security
Setting up Local Package Process
Examining /tmp/openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch.rpm: openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch
Marking /tmp/openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch.rpm as an update to openshift-origin-node-proxy-1.26.1-1.git.1103.c6cf7cf.el6.noarch
--> Running transaction check
---> Package openshift-origin-node-proxy.noarch 0:1.26.1-1.git.1103.c6cf7cf.el6 will be updated
---> Package openshift-origin-node-proxy.noarch 0:1.26.2.1-1.el6op will be an update
--> Finished Dependency Resolution

Dependencies Resolved

=======================================================================================================================
 Package                      Arch    Version              Repository                                             Size
=======================================================================================================================
Updating:
 openshift-origin-node-proxy  noarch  1.26.2.1-1.el6op     /openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch  100 k

Transaction Summary
=======================================================================================================================
Upgrade       1 Package(s)

Total size: 100 k
Is this ok [y/N]: y
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Warning: RPMDB altered outside of yum.
  Updating   : openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch                                                 1/2 
warning: /etc/openshift/web-proxy-config.json created as /etc/openshift/web-proxy-config.json.rpmnew
[  OK  ] node-web-proxy: [  OK  ]
Starting node-web-proxy: [  OK  ]
  Cleanup    : openshift-origin-node-proxy-1.26.1-1.git.1103.c6cf7cf.el6.noarch                                    2/2 
  Verifying  : openshift-origin-node-proxy-1.26.2.1-1.el6op.noarch                                                 1/2 
  Verifying  : openshift-origin-node-proxy-1.26.1-1.git.1103.c6cf7cf.el6.noarch                                    2/2 

Updated:
  openshift-origin-node-proxy.noarch 0:1.26.2.1-1.el6op                                                                
Complete!
--------------------------------------------------------------

# ls /etc/openshift | grep web-proxy
web-proxy-config.json
web-proxy-config.json.rpmnew

Could you re-test please? If this fails again, please provide the old version, the new version, and the modification you made to the web-proxy-config.json so we can investigate.

Comment 12 Anping Li 2016-03-07 07:43:41 UTC
It work well now.

---> Package openshift-origin-node-proxy.noarch 0:1.25.1.1-1.el6op will be updated
---> Package openshift-origin-node-proxy.noarch 0:1.26.2.1-1.el6op will be an update
ls -1 /etc/openshift/web-proxy-config.json*
/etc/openshift/web-proxy-config.json
/etc/openshift/web-proxy-config.json.rpmnew

Comment 14 errata-xmlrpc 2016-03-22 16:54:09 UTC
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://rhn.redhat.com/errata/RHSA-2016-0489.html


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