-
Notifications
You must be signed in to change notification settings - Fork 306
PHP Built-In Server HTTP error: Error: connect ECONNREFUSED 127.0.0.1:8000 #541
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
Comments
Fixed! Changed the json to:
|
sorry, but where is the different |
got same error but above does not work. |
Same error here |
I was able to deploy the basic examples by setting Node.js version to 18.x on Vercel's project settings, I've tried I had the same error |
The same just want to write comment. |
Hi folks. Node 20.x seems to be problem. I need to investigate it. |
i get error how to fix it |
I had the same problem with node 20x. I created package.json file and add this code to use node 18x version. package.json The project is running without any issue |
I had the same problem. |
I managed to get it working by changing the Node.js Version in the Settings -> General on Vercel web page. |
Are you using Node 18.x? Node 20.x is a problem. |
yeah i have made that change |
this solution works! thanks
|
I know Vercel uses Node.js to build our project and for the creation of Serverless Functions but I didn't quite understand the role of "runtime":"[email protected]" An explanation would be greatly appreciated. |
vercel.json-
package.json- Works 👍 |
The error is:
Node 20.x image has no libssl.so.10 |
I have seen that the Node.js 18 will be retired on Vercel next year (Early 2025). |
PHP use libssl.so in |
This solution worked for me: {
"functions": {
"api/index.php": {
"runtime": "[email protected]"
}
},
"rewrites": [
{ "source": "/(.*)", "destination": "/api/index.php" }
]
} And change node.js version to |
So with no libssl.so, basically CURL will be dead right? |
Why is not specified in the readme that Node 18.x must be selected? (I made a PR #569) |
For anyone still faced with this issue, do the following Step 1: Use a working exampleStep 2: replace the
|
Hey all! It should be fixed to use Node 20.x, can you folks try version |
Hey, I was testing this package and I set up the example and I got this error: PHP Built-In Server HTTP error: Error: connect ECONNREFUSED 127.0.0.1:8000. The vercel deployed but when I visit the website it shows that error.
NOTE: I deployed it all using GitHub and vercel online, I did not install Node.JS or the Vercel CLI on my local machine. Do I need to do that?
The site if you want to see for yourself: https://testvercelphp.vercel.app/
My test file structure:
vercel.json
api/
├─ index.php
vercel.json:
{
"functions": {
"api/index.php": {
"runtime": "[email protected]"
}
},
"routes": [
{ "src": "/(.*)", "dest": "/api/index.php" }
]
}
index.php:
The text was updated successfully, but these errors were encountered: