简体   繁体   English

在运行Laravel Envoy任务时,“stdin不是终点”

[英]“stdin is not a terminal” when run Laravel Envoy tasks

One month later, all commands works great, but now... 一个月后,所有命令都运行良好,但现在......

When I try run envoy run deploy 当我尝试运行envoy run deploy

@servers([
    'mt' => 'user@xxxx.xxxx.xxxx'
])

@task('deploy', ['on' => 'mt'])
    cd /var/www/html/xxx.xxxxxx.xxxx
    git pull origin dev
    composer dump-autoload -o
    php artisan cache:clear
@endtask

I get this error: 我收到此错误:

git:(dev) ✗ envoy run deploy
[]: Pseudo-terminal will not be allocated because stdin is not a terminal.
[]: ssh: Could not resolve hostname bash -s: nodename nor servname provided, or not known

I put the content of my id_rsa.pub in the server authorized_keys , and the normal login works well, for example: ssh user@xxx.xxx.xxx - I can login without a password. 我将id_rsa.pub的内容放在服务器authorized_keys ,正常登录效果很好,例如: ssh user@xxx.xxx.xxx - 我可以在没有密码的情况下登录。

So... what I'm doing wrong? 那么......我做错了什么?


I'm using: 我正在使用:

  • php 5.6 PHP 5.6
  • zsh + oh-my-zsh zsh + oh-my-zsh
  • iTerm 2 iTerm 2
  • Yosemite 优胜美地

If you need more details, tell me after down vote please. 如果您需要更多详细信息,请在投票后告诉我。

Thanks. 谢谢。

I found the solution, but still I don't think that's it. 我找到了解决方案,但我仍然认为不是这样。

That's my code: 那是我的代码:

@servers([
    'mt' => 'user@xxxx.xxxx.xxxx'
])

Tha the solution: 解决方案:

@servers(['mt' => 'user@xxxx.xxxx.xxxx'])

The server function must be entire inline . 服务器功能必须是整个内联

Thank's for you time guys! 谢谢你的时间!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM