• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space
  • Chevereto Support CLST

    Support response

    Support checklist

    • Got a Something went wrong message? Read this guide and provide the actual error. Do not skip this.
    • Confirm that the server meets the System Requirements
    • Check for any available Hotfix - your issue could be already reported/fixed
    • Read documentation - It will be required to Debug and understand Errors for a faster support response

cron on nginx

sirfpsycho

Chevereto Member
Hello, I am using cron on nginx based server. I have added cron with this command:
/www/server/php/74/bin/php /www/wwwroot/data/domain.com/cli.php -C cron

I don't know above command is ok or not. In whmcs when I use cron then there is -q after php like this:
/www/server/php/74/bin/php -q /www/wwwroot/xxx/pip.php

so is it necessary to add -q here too or it is fine without it?

++++++ After executing cron it gives below log:

  • Processing removeDeleteLog
  • Processing storageDelete
  • Processing tryForUpdates
  • Processing checkHtaccess
  • Enforce .htaccess files

Aw, snap! Internal Server Error [debug @ error_log]

** errorId #1d6ae7738b417438 **
> ErrorException [0]: file_put_contents(app/.htaccess): failed to open stream: No such file or directory
At /www/wwwroot/data/domain.com/app/htaccess-enforce.php:33

Stack trace:
#0 unknown file(unknown line): G\errorsAsExceptions()
#1 /www/wwwroot/data/domain.com/app/htaccess-enforce.php(33): file_put_contents()
#2 /www/wwwroot/data/domain.com/app/cron.php(112): include('/www/wwwroot/data/domain.com/app/htaccess-enforce.php')
#3 /www/wwwroot/data/domain.com/app/cron.php(32): checkHtaccess()
#4 /www/wwwroot/data/domain.com/app/loader.php(233): require_once('/www/wwwroot/data/domain.com/app/cron.php')
#5 /www/wwwroot/data/domain.com/cli.php(36): include_once('/www/wwwroot/data/domain.com/app/loader.php')


Here I replaced my domain with domain.com
As I am using nginx so there is no htaccess and in this log there is htaccess word and other error too. Are these error ignorable?
 
so is it necessary to add -q here too or it is fine without it?
The -q flag is for quiet-mode. 👉 http://man.he.net/?topic=php&section=all

Quiet-mode. Suppress HTTP header output (CGI only).

I don't know if is needed.

** errorId #1d6ae7738b417438 **
At /www/wwwroot/data/domain.com/app/htaccess-enforce.php:33
Make sure you uploaded all the system files, including app/.htaccess and that permissions in that path enable .php to write files there.
 
Make sure you uploaded all the system files, including app/.htaccess and that permissions in that path enable .php to write files there.
which path and files needs which permission? app folder has 755 and htaccess has 644. and I am using nginx so htaccess is not usable in nginx.
 
Simply provide the file at app/.htaccess and it should work for you. Sadly, at CLI there's no "server" so we can't detect nginx there. There's a setting key to disable the htaccess enforcement but we haven't documented it yet.

PHP:
$settings['htaccess_enforce'] = false;
 
Back
Top