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

lighttpd.conf needs doesn't work #1876

Open
f3bruary opened this issue Feb 19, 2018 · 6 comments
Open

lighttpd.conf needs doesn't work #1876

f3bruary opened this issue Feb 19, 2018 · 6 comments
Labels

Comments

@f3bruary
Copy link

I moved the lighttpd.conf to /etc/lighttpd/conf-available/. Right now the server can only load the default page, but no other pages (404).

Now I do:
lighty-enable-mod lighttpd
which enables the config. But after this lighttpd won't start anymore. The logs mention multiple files (the server config, the grav config and the perl file that includes configs).

When I disable the config, the default page works again, but nothing else.

The only thing I changed in the config was (using vim):
:%s/\/grav_path\///g
and I manually edited the one on line 45 (removed "/grav_path").

@rhukster
Copy link
Member

You should rename all the references to /grav_path with your actual path to the server as noted in the file:

############# DO NOT FORGET TO CHANGE "grav_path" BY YOUR ACTUAL GRAV INSTALLATION FOLDER #############
############# IF GRAV IS AT THE ROOT OF YOUR WEBSITE, ie http://yoursite.tld POINTS TO    #############
############# GRAV DIRECTLY, THEN JUST REMOVE ANY "/grav_path/" MENTION BELOW. OTHERWISE  #############
############# WE ASSUME YOU RUN AN INSTALLATION SUCH AS http://yoursite.tld/grav_path/    #############
#######################################################################################################

@f3bruary
Copy link
Author

I did like I mentioned before. Grav is sitting in the www root. So I replaced all instances of /grav_path/ with null (thus removing it). I also tried replacing /grav_path/ with '/'. Didn't work either.

@f3bruary
Copy link
Author

Fixed by commenting out:

#url.access-deny = (".md","~",".inc")

@iulian3144
Copy link

A little bit late, but after 3 years since this issue has been reported it seems that the lighttpd configuration still doesn't work out of the box.

An alternative which seems to be working on my side, is the following:

-url.access-deny = (".md","~",".inc")
+url.access-deny += (".md","~",".inc")

Probably better than commenting the line, IMO. Based on the documentation, this should append the additional extensions to the option. It also works with := (replace/overwrite earlier value). Still not sure why it doesn't work with a simple =.

@mahagr mahagr reopened this Jan 20, 2021
@mahagr
Copy link
Member

mahagr commented Jan 20, 2021

@iulian3144 As you're on it, please look if you can match the rules from .htaccess file as it has been updated to prevent more attacks and folders in the installation.

None of the developers have the Lighttpd server installed making me scared to update the file blindly.

@mahagr mahagr added bug and removed question labels Jan 20, 2021
@iulian3144
Copy link

@mahagr I actually started messing with lighttpd the day before I added my comment.
I'll have a look though when I'll find some time.

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

No branches or pull requests

4 participants