Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong path to static #8

Open
itJunky opened this issue Sep 27, 2017 · 2 comments
Open

Wrong path to static #8

itJunky opened this issue Sep 27, 2017 · 2 comments

Comments

@itJunky
Copy link

itJunky commented Sep 27, 2017

2017/09/27 23:56:04 [error] 5014#5014: *34 open() "/usr/share/backuppc/cgi-bin/backuppc/image/BackupPC_stnd.css" failed (2: No such file or directory), client: 2.93.191.179, server: _, request: "GET /backuppc/image/BackupPC_stnd.css HTTP/1.1", host: "138.68.101.254"

Real path is /usr/share/backuppc/cgi-bin/image/BackupPC_stnd.css

I think need use "location /" instead "location /backuppc". Or another location for static.

@itJunky
Copy link
Author

itJunky commented Sep 28, 2017

My solution is:

 location ~\.(css|js|ico|gif|png)$ {
   root /usr/share/;
 }

@RasmusAntons
Copy link

My solution is:

location ~\.(css|js|ico|gif|png)$ {
  root /usr/share/;
}

That allows anyone to request all such files from /usr/share. My also hacky solution is to symlink the cgi-bin directory into itself with ln -s /usr/share/backuppc/cgi-bin/ /usr/share/backuppc/cgi-bin/backuppc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants