0

重新安装 Kubuntu 后,我在使用 ssh 运行特使时遇到问题。我将 700 设置为配置文件,但仍然出现错误:

$ sudo chmod  700  /home/serge/.ssh/config
serge@athoe:/mnt/_work_sdb8/wwwroot/lar/hostels2$ envoy run Hostels2Deploy  --app_version=0.112 --run_migration=1   --run_migration_seed=1                                                                                                   
PHP Warning:  file_get_contents(/home/serge/.ssh/config): failed to open stream: Permission denied in /home/serge/.composer/vendor/laravel/envoy/src/SSHConfigFile.php on line 35                                                            

Warning: file_get_contents(/home/serge/.ssh/config): failed to open stream: Permission denied in /home/serge/.composer/vendor/laravel/envoy/src/SSHConfigFile.php on line 35                                                                 
[laravelserver]: ssh: Could not resolve hostname laravelserver: Name or service not known                                                                                                                                                    
This task did not complete successfully on one of your servers.   

如何解决?

修改: 它看起来不像特使文件的问题,因为它在重新安装 Kubuntu 之前工作搜索我下一步运行的决定:

sudo chmod -R 777 /home/serge/.composer/config.json
sudo chown serge /home/serge/.composer/config.json

但我收到消息说 /home/serge/.composer/config.json 找不到。然后我从之前的家庭安装中获取它的内容:

{
    "require": {
        "laravel/envoy": "^1.6",
        "laravel/installer": "~1.1"
    }
}

并运行

sudo service sshd restart

但仍然得到这个错误。我有 :

$ composer -v
...
Composer 1.6.3 2018-01-31 16:28:17

作曲家或其许可有问题,因为我没有 /home/serge/.composer/config.json 文件?

采取哪些步骤?

4

1 回答 1

0

我发现这个.composer/config 文件权限被拒绝使用 laravel分支和命令之后:

 sudo chmod  744  /home/serge/.ssh/config

帮助过我 !

于 2019-10-10T03:36:58.470 回答