Skip to content
This repository has been archived by the owner on Jan 25, 2022. It is now read-only.

cf files command throws error when attempting to get a file with the name ^application.* #61

Closed
cdavisafc opened this issue Sep 12, 2013 · 1 comment

Comments

@cdavisafc
Copy link

○ → cf files helloplay
Getting file contents... OK

.bash_logout                              220B
.bashrc                                   3.0K
.profile                                  675B
app/                                         -
application.log                             5B
logs/                                        -
run.pid                                     3B
staging_info.yml                          284B
testperm/                                    -
tmp/                                         -

Now try to access the file "application.log"

○ → cf files helloplay application.log
Getting file contents... FAILED
CFoundry::BadResponse: 405: <html>
<head><title>405 Not Allowed</title></head>
<body bgcolor="white">
<center><h1>405 Not Allowed</h1></center>
<hr><center>nginx</center>
</body>
</html>

Changing the name of the file (via a wsh into the warden container) and nothing else:

○ → cf files helloplay
Getting file contents... OK

.bash_logout                              220B
.bashrc                                   3.0K
.profile                                  675B
app/                                         -
foo.txt                                     5B
logs/                                        -
run.pid                                     3B
staging_info.yml                          284B
testperm/                                    -
tmp/                                         -

 |system||ruby-1.9.3-p392| cornelia in ~/.ssh
○ → cf files helloplay foo.txt
Getting file contents... OK

test

Some experimentation shows that filenames matching the regex ^application.* are all a problem.

Cross posted an issue into cf repo as I'm not sure whether it is a cli or router issue. router issue #4

@mmb
Copy link
Contributor

mmb commented Sep 20, 2013

The nginx in front of cloud controller is matching application and returning 405 due to this config:

https://github.com/cloudfoundry/cf-release/blob/master/jobs/cloud_controller_ng/templates/nginx.conf.erb#L80

@cdavisafc Could you reopen this issue in cf-release and reference this one?

cc @MarkKropf

@mmb / @matthewmcnew

@mmb mmb closed this as completed Sep 20, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants