1

是否可以在 Laravel 5.7 应用程序中通过特使使用 https 访问 bitbucket 代表?运行特使命令我得到错误:

$ envoy run deploy
deployeruser@138.68.107.4's password:
[deployeruser@138.68.107.4]: Cloning into '20190309072721'...
[deployeruser@138.68.107.4]: remote: Repository client/project_name.git  not found
[deployeruser@138.68.107.4]: fatal: repository 'https://myaccount@bitbucket.org/client/project_name.git /var/www/html/project_name/release/20190309072721/' not found
[✗] This task did not complete successfully on one of your servers.

其中https://myaccount@bitbucket.org是我的帐户,client/project_name.git 是我要克隆的项目

我在https://laravel.com/docs/5.7/envoy没有找到这样的选项

如果我在控制台中运行命令:

git clone https://myaccount@bitbucket.org/client/project_name.git

在目标服务器(ubuntu 18 ubder Digital Ocean)上它被克隆了。

修改: 在我的特使文件中,我的结构如下:

@setup
    $server_login_user= 'deployer_user';
    ...
    # $repo= 'git clone git@bitbucket.org:myaccount/votes.git';
    $repo= 'git clone https://myaccount@bitbucket.org/myaccount/votes.git';

    $branch= '';


@endsetup

@servers(['production' => $server_login_user.'@NNN.NN.NN.NN'])


@task( 'clone', ['on'=>$on] )

    git clone {{ $branch }} "{{ $repo }} {{ $release_number }}"
@endtask

但是在控制台中运行特使我得到了错误:

$ envoy run Deploy
deployer_user@NNN.NN.NN.N's password: 
[deployer_user@NNN.NN.NN.N]: Cloning into 'dest_directory'...
[deployer_user@NNN.NN.NN.N]: fatal: I don't handle protocol 'git clone https'
[✗] This task did not complete successfully on one of your servers.

问题是我在我的服务器上遇到了 ssh 问题,如果可能的话,我更愿意在这里使用 http……

谢谢!

4

0 回答 0