嘗試shell_exec在本地服務(wù)器上使用 php 執(zhí)行 aws cli 命令(用于測(cè)試)。我正在使用 xampp、windows 操作系統(tǒng)、Laravel 和 php,我在 windows 上安裝了 aws cli。Windows cmd 可以識(shí)別 aws 命令,但是當(dāng)我嘗試執(zhí)行 aws 命令時(shí)shell_exec出現(xiàn)錯(cuò)誤:“aws is not Recognized as an internal or external command”。嘗試了這個(gè)簡(jiǎn)單的腳本:$exec = shell_exec('aws --version');$exec return null.感謝任何幫助。
如何使用 shell_exec 執(zhí)行 aws cli 命令?
慕的地6264312
2022-07-09 16:56:24