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

grav with H2O webserver error #1760

Closed
s0kil opened this issue Nov 21, 2017 · 4 comments
Closed

grav with H2O webserver error #1760

s0kil opened this issue Nov 21, 2017 · 4 comments

Comments

@s0kil
Copy link

s0kil commented Nov 21, 2017

My Error Log File
starting new worker 32649
[INFO] raised RLIMIT_NOFILE to 1048576
h2o server (pid:32649) is ready to serve requests
[lib/handler/fastcgi.c] in request:/index.php/:PHP Fatal error: Uncaught RuntimeException: Opening file for writing failed on error fopen(/var/www/html/cache//compiled/files/b296ac48b18c22fb9ad19958ded5d09f.yaml.php): failed to open stream: Permission denied in /var/www/html/vendor/rockettheme/toolbox/File/src/File.php:202
Stack trace:
#0 /var/www/html/vendor/rockettheme/toolbox/File/src/File.php(320): RocketTheme\Toolbox\File\File->lock()
#1 /var/www/html/vendor/rockettheme/toolbox/File/src/PhpFile.php(31): RocketTheme\Toolbox\File\File->save(Array)
#2 /var/www/html/system/src/Grav/Common/File/CompiledFile.php(67): RocketTheme\Toolbox\File\PhpFile->save(Array)
#3 /var/www/html/system/src/Grav/Common/Config/Setup.php(178): Grav\Common\File\CompiledYamlFile->content()
#4 /var/www/html/system/src/Grav/Common/Processors/SiteSetupProcessor.php(18): Grav\Common\Config\Setup->init()
#5 /var/www/html/system/src/Grav/Common/Grav.php(132): Grav\Common\Processors\SiteSetupProcessor->process()
#6 /var/www/html/system/src/Grav/Common/Grav.php(379): Grav\Common\Grav->Grav\Common{clos in /var/www/html/system/src/Grav/Common/File/CompiledFile.php on line 83

My h20 conf File
hosts:
"localhost:80":
listen:
port: 80
host: 0.0.0.0
paths:
"/":
file.dir: /var/www/html
redirect:
url: /index.php/
internal: YES
status: 307

file.custom-handler:
extension: .php
fastcgi.spawn: "PHP_FCGI_CHILDREN=10 exec /usr/bin/php-cgi"

access-log: /var/log/h2o/access.log
error-log: /var/log/h2o/error.log
pid-file: /var/run/h2o/h2o.pid
#http2-reprioritize-blocking-assets: ON

@rhukster
Copy link
Member

Never heard of it! Anyone else use this webserver that might have an idea?

@s0kil
Copy link
Author

s0kil commented Nov 23, 2017

Problem Solved.
h2o/h2o#1507

@rhukster
Copy link
Member

Maybe you could provide a sample config for H2O server for the webserver-configs directory?

@s0kil
Copy link
Author

s0kil commented Nov 25, 2017

Here is my h2o.conf file working perfectly.

file.etag: on
compress-minimum-size: 0
expires: off
compress: on
file.dirlisting: off
file.send-compressed: on
access-log: /var/log/h2o/access.log
error-log: /var/log/h2o/error.log
pid-file: /var/run/h2o/h2o.pid
http2-reprioritize-blocking-assets: on
user: www-data
hosts:
  "localhost:80":
    listen:
      port: 80
      host: 0.0.0.0
      "/grav":
        file.dir: /var/www/html/grav/
        redirect:
          url: /grav/index.php
          internal: YES
          status: 307
file.custom-handler:
  extension: .php
  fastcgi.connect:
    port: /run/php/php7.1-fpm.sock
    type: unix

@s0kil s0kil closed this as completed Nov 25, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants