Bug 966759 - Front end mappings not starting with / are added without the / to the frontend
Front end mappings not starting with / are added without the / to the frontend
Status: CLOSED CURRENTRELEASE
Product: OpenShift Online
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
Unspecified Unspecified
unspecified Severity medium
: ---
: ---
Assigned To: Jhon Honce
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-23 17:52 EDT by Dan McPherson
Modified: 2015-05-14 19:19 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-06-11 00:10:17 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)

  None (edit)
Description Dan McPherson 2013-05-23 17:52:13 EDT
Description of problem:
Ex:

Endpoints:
  - Private-IP-Name:   IP
    Private-Port-Name: PORT
    Private-Port:      8080
    Public-Port-Name:  PROXY_PORT
    Mappings:
      - Frontend:      "/phpmyadmin"
        Backend:       "/phpmyadmin"


works but

Endpoints:
  - Private-IP-Name:   IP
    Private-Port-Name: PORT
    Private-Port:      8080
    Public-Port-Name:  PROXY_PORT
    Mappings:
      - Frontend:      "phpmyadmin"
        Backend:       "/phpmyadmin"

Will add a mapping that looks like:

blah3-danmcp7.dev.rhcloud.comphpmyadmin 127.0.251.131:8080/phpmyadmin

I didn't check but the Backend mapping needs to be verified and possibly fixed as well to add the / if not found.


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


How reproducible:


Steps to Reproduce:
1. Modify a manifest in a cart to have a front end mapping not starting with /
2. Create the app with that cart
3. Make sure the expected url works
4. Delete the cart and check /var/lib/openshift/.httpd.d/nodes.txt to make sure we find the entry correctly on delete as well.

Actual results:
Incorrect mapping added

Expected results:
Correct mapping added


Additional info:
Comment 1 Jhon Honce 2013-05-23 20:09:44 EDT
Fixed in https://github.com/openshift/origin-server/pull/2625
Comment 2 openshift-github-bot 2013-05-24 00:40:42 EDT
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/1dab84a982ba2350b3c0495fd52aebb58ed043f3
Bug 966759 - Ensure mappings start with /

* If cartridge authors forget the leading / on mappings, add it
Comment 3 Xiaoli Tian 2013-05-24 06:20:18 EDT
Reproduced it on devenv_3268 by removing the leading / from the manifest file of the custom phpmyadmin cartridge:
    Public-Port-Name:  PROXY_PORT
    Mappings:
      - Frontend:      "phpmyadmin"
        Backend:       "phpmyadmin"

After adding phpmyadmin, the frontend will be like the following:

[root@ip-10-62-13-202 conf]# cat  /var/lib/openshift/.httpd.d/nodes.txt |grep phpmyadmin
phpapp-domx1.dev.rhcloud.comphpmyadmin 127.0.252.131:8080phpmyadmin

Verified it on devenv_3269:

After adding phpmyadmin with the leading / removed from the manifest file,  phpmyadmin could still be accessed, the frontend entry is written correctly:

[root@ip-10-145-231-250 .httpd.d]# cat nodes.txt |grep phpmyadmin
phpapp-domx1.dev.rhcloud.com/phpmyadmin 127.0.250.131:8080/phpmyadmin

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