将php程序扔在主目录即可
{
"functions": {
"api/index.php": {
"runtime": "vercel-php@0.5.2"
}
},
"routes": [
{ "src": "/(.*)", "dest": "/api/index.php" }
]
}
对于的php本版为
vercel-php@0.5.2
- PHP 8.1.xvercel-php@0.4.0
- PHP 8.0.xvercel-php@0.3.2
- PHP 7.4.x
使用低于 "vercel-php@0.5.2" 版本可能会构建失败