[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

404 on path based route



Using OSEv3.1.1

I have an app with a dynamic and static content. I'm trying to manipulate routes such that / is served by the dynamic gunicorn service and /static is served by a simple apache service.

Configured as follows, I am seeing a 404 on my /static route. Am I missing something obvious?


$ oc describe service hello-flask
Name:                   hello-flask
Namespace:              dale
Labels:                 app=hello-flask
Selector:               deploymentconfig=hello-flask
Type:                   ClusterIP
IP:                     172.30.15.193
Port:                   8080-tcp        8080/TCP
Endpoints:              10.1.6.6:8080
Session Affinity:       None
No events.

$ oc describe service home-nfs
Name:                   home-nfs
Namespace:              dale
Labels:                 template=static-webserver
Selector:               name=home-nfs
Type:                   ClusterIP
IP:                     172.30.206.133
Port:                   web     8080/TCP
Endpoints:              10.1.7.11:8080
Session Affinity:       None
No events.

$ oc describe route hello-flask
Name:                   hello-flask
Created:                13 days ago
Labels:                 app=hello-flask
Annotations:            openshift.io/generated-by=OpenShiftWebConsole
                        openshift.io/host.generated=true
Host:                   hello-flask-dale.os.example.com
Path:                   <none>
Service:                hello-flask
TLS Termination:        <none>
Insecure Policy:        <none>

$ oc describe route static-content-test
Name:                   static-content-test
Created:                20 hours ago
Labels:                 template=static-webserver
Host:                   hello-flask-dale.os.example.com
Path:                   /static                 <----- notice!
Service:                home-nfs
TLS Termination:        <none>
Insecure Policy:        <none>


$ curl -I home-nfs-dale.os.example.com/index.html
HTTP/1.1 200 OK
Date: Tue, 05 Apr 2016 16:53:47 GMT
Server: Apache/2.4.6 (CentOS)
Last-Modified: Sat, 19 Mar 2016 01:01:17 GMT
ETag: "4-52e5c669fdc84"
Accept-Ranges: bytes
Content-Length: 4
Content-Type: text/html; charset=UTF-8
Set-Cookie: OPENSHIFT_dale_home-nfs_SERVERID=10.1.7.11:8080; path=/; HttpOnly
Cache-control: private

$ curl -I hello-flask-dale.os.example.com
HTTP/1.0 200 OK
Content-Type: application/json
Content-Length: 100
Server: Werkzeug/0.8.3 Python/2.7.8
Date: Tue, 05 Apr 2016 16:53:50 GMT
Set-Cookie: OPENSHIFT_dale_hello-flask_SERVERID=10.1.6.6:8080; path=/; HttpOnly
Cache-control: private
Connection: keep-alive

$ curl -I hello-flask-dale.os.example.com/static/index.html
HTTP/1.1 404 Not Found                    <----- notice!
Date: Tue, 05 Apr 2016 16:53:56 GMT
Server: Apache/2.4.6 (CentOS)
Content-Type: text/html; charset=iso-8859-1
Set-Cookie: OPENSHIFT_dale_static-content-test_SERVERID=10.1.7.11:8080; path=/; HttpOnly


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]