XF 2.0 XF2 creating addon via CLI and I continue to get "no Such file or directory"

Chris D

XenForo developer
Staff member
It likely suggests that the src/addons directory is not writeable by whichever user the command is running as.

Are you developing on a remote server or a local server (e.g. WAMP or similar?)
 

Dannymh

Active member
It likely suggests that the src/addons directory is not writeable by whichever user the command is running as.

Are you developing on a remote server or a local server (e.g. WAMP or similar?)
Developing locally with bitnami installed on mac, directory has full Read and Write access
 

Mike

XenForo developer
Staff member
If you add --verbose when you run the command, it should give a full backtrace. (Alternatively, there's probably one logged in the control panel.)
 

Dannymh

Active member
If you add --verbose when you run the command, it should give a full backtrace. (Alternatively, there's probably one logged in the control panel.)
Verbose isnt giving me any more cluse

Code:
dmba2:XF2 dmba$ php cmd.php xf-addon:create --verbose
Enter an ID for this add-on: Silvertails/demo
No such file or directory
Enter an ID for this add-on:
Also nothing is going into the admin logs either
 

Dannymh

Active member
i'll run it up on my linux machine later and see if I can get it working, however would prefer it working on the mac as its my main and travel computer
 

Chris D

XenForo developer
Staff member
Certainly should work on a Mac.

I'm actually quite confused because there really shouldn't be anything happening between answering that question and the next question.

The only thing we do is check if the add-on files already exist, but even then we would return a sensible error.


Just to check - are you running Beta 7?
 

Mike

XenForo developer
Staff member
This is quite possibly DB related and your CLI PHP is looking for the DB connection socket at a different location than your web server. If you change your src/config.php to 127.0.0.1 instead of localhost and that fixes it, that's the cause.
 

Dannymh

Active member
This is quite possibly DB related and your CLI PHP is looking for the DB connection socket at a different location than your web server. If you change your src/config.php to 127.0.0.1 instead of localhost and that fixes it, that's the cause.
Winner that fixed it thank you!
 

mcatze

Well-known member
I had the same problem. The folders are writeable and also change localhost to 127.0.0.1 changes nothing.

I use Mamp Pro 4.2.1 on a Mac and got the following errors if i want to create an add-on.

Code:
Matthiass-Mini:xen2 McAtze$ php cmd.php xf-addon:create --verbose
Enter an ID for this add-on: ITM/Cookies
 Connection refused
Enter an ID for this add-on:
 

Chris D

XenForo developer
Staff member
Did you make the IP change in src/config.php rather than library/config.php?
 

mcatze

Well-known member
I changed in src/config.php and not in library/config.php

How does library/config.php work with xenforo 2?
 

ALMUSA

Well-known member
Im having the same issue No such file or directory and when I changed conf.php from localhost to 127.0.0.1 I get connection refused.
 

MJD

Member
Same issue. The tutorial listed here doesn't work on MAMP / Mac.

Changed the config file to have 127.0.0.1 and it still doesn't work.

Screen Shot 2018-04-11 at 9.10.40 PM.png

Any further suggestions on getting the tutorial to work as detailed?
 

mcatze

Well-known member
I used now ScotchBoxPro and do all stuff from your dev tutorial, but i've also the same issue "No such file or directory".

What should i do @Chris D @Mike ??
 

mcatze

Well-known member
Whats should i do with this error message? I use the scotchbox like you describe in the dev docs.

Screenshot 2018-04-15 18.54.09.png
 
Doesn't look like you've connected to your ScotchBox. Go to the base directory and enter vagrant ssh. This should connect you to your vagrant box. Go to the xenforo directory, probably somewhere in /var/www/, and run the command from there.
 

Deceptive

Active member
I had the same problem. The folders are writeable and also change localhost to 127.0.0.1 changes nothing.

I use Mamp Pro 4.2.1 on a Mac and got the following errors if i want to create an add-on.

Code:
Matthiass-Mini:xen2 McAtze$ php cmd.php xf-addon:create --verbose
Enter an ID for this add-on: ITM/Cookies
Connection refused
Enter an ID for this add-on:
Did you ever find a solution? I have the same problem
 
Top