PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Wednesday, March 9, 2022

[FIXED] cronjob path is wrong for cake3 project

 March 09, 2022     cakephp, cakephp-3.0, php     No comments   

Issue

In cakephp3 I cannot get my cronjob to run as I keep getting /bin/bash: bin/cake: No such file or directory from the email feedback I set in my cpanel

The file is in the folder called Shell in the project and the file name is called invoicingShell.php

The folder of bin is in the cakephp3 project where it should be and I am using a linux OS. What am I doing wrong?

My cronjob is set in cronjobs Cpanel (every min for testing) i omitted the real account name below

cd /home/myaccount/public_html/crm/src && bin/cake invoicing postpaid

Solution

You have messed your application structure somehow, because in official CakePHP Skeleton app, directory structure is like

ROOT
├───bin
     └───cake
     └───cake.bat
     └───cake.php
├───config
├───logs
├───plugins
├───src
├───tests
├───tmp
├───vendor
├───webroot

See https://github.com/cakephp/app



Answered By - makallio85
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

1,259,307

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © 2025 PHPFixing