request_script.sh 448 B

123456789101112131415161718192021
  1. #!/bin/bash
  2. # 将特定的命令列表赋给变量
  3. COMMANDS=(
  4. "/usr/bin/php81 artisan buildStory"
  5. "/usr/bin/php81 artisan buildTitle"
  6. "/usr/bin/php81 artisan buildKeyword"
  7. "/usr/bin/php81 artisan buildSd"
  8. "/usr/bin/php81 artisan getOpensdDetail"
  9. "/usr/bin/php81 artisan buildPinyin"
  10. )
  11. while true
  12. do
  13. for command in "${COMMANDS[@]}"
  14. do
  15. $command # 执行特定命令
  16. done
  17. sleep 5 # 休眠5秒
  18. done