2

我不再能够通过 ssh 通过 git ftp 连接到我的 sftp 服务器。我现在收到以下错误:

Failure establishing ssh session

我最后一次成功推送是在 2018 年 5 月 14 日。

我目前正在使用 BitBucket Pipelines。我的 YML 文件如下所示:

image: php:7.0.27

pipelines:
  default:
    - step:
        script:
          - apt-get update
          - apt-get -qq install git-ftp
          - git ftp push --user $SFTP_username --passwd $SFTP_password --verbose sftp://[domain]/.../

据我所知,没有任何改变(变量、主机、路径等)。

git-ftp 或 BitBucket Pipelines 有什么变化吗?

详细日志如下:

失败 - 2018 年 7 月 4 日

+ umask 000

+ GIT_LFS_SKIP_SMUDGE=1 git clone --branch="master" --depth 50 [auth token] $BUILD_DIR ; git reset --hard cfd69a33f41add0a81bc04a2bf81e0c0abc1a0b9 ; git remote set-url origin [git path]
Cloning into '/opt/atlassian/pipelines/agent/build'...
HEAD is now at cfd69a3 Retrying blockquote link text color update

+ chmod 777 $BUILD_DIR

+ apt-get update
Get:1 http://security.debian.org jessie/updates InRelease [44.9 kB]
Ign http://deb.debian.org jessie InRelease
Get:2 http://deb.debian.org jessie-updates InRelease [145 kB]
Get:3 http://security.debian.org jessie/updates/main amd64 Packages [592 kB]
Get:4 http://deb.debian.org jessie Release.gpg [2420 B]
Get:5 http://deb.debian.org jessie Release [148 kB]
Get:6 http://deb.debian.org jessie-updates/main amd64 Packages [23.0 kB]
Get:7 http://deb.debian.org jessie/main amd64 Packages [9098 kB]
Fetched 10.1 MB in 5s (1835 kB/s)
Reading package lists...

+ apt-get -qq install git-ftp
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package libpopt0:amd64.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 12703 files and directories currently installed.)
Preparing to unpack .../libpopt0_1.16-10_amd64.deb ...
Unpacking libpopt0:amd64 (1.16-10) ...
Selecting previously unselected package libcurl3-gnutls:amd64.
Preparing to unpack .../libcurl3-gnutls_7.38.0-4+deb8u11_amd64.deb ...
Unpacking libcurl3-gnutls:amd64 (7.38.0-4+deb8u11) ...
Selecting previously unselected package libexpat1:amd64.
Preparing to unpack .../libexpat1_2.1.0-6+deb8u4_amd64.deb ...
Unpacking libexpat1:amd64 (2.1.0-6+deb8u4) ...
Selecting previously unselected package libxau6:amd64.
Preparing to unpack .../libxau6_1%3a1.0.8-1_amd64.deb ...
Unpacking libxau6:amd64 (1:1.0.8-1) ...
Selecting previously unselected package libxdmcp6:amd64.
Preparing to unpack .../libxdmcp6_1%3a1.1.1-1+b1_amd64.deb ...
Unpacking libxdmcp6:amd64 (1:1.1.1-1+b1) ...
Selecting previously unselected package libxcb1:amd64.
Preparing to unpack .../libxcb1_1.10-3+b1_amd64.deb ...
Unpacking libxcb1:amd64 (1.10-3+b1) ...
Selecting previously unselected package libx11-data.
Preparing to unpack .../libx11-data_2%3a1.6.2-3+deb8u1_all.deb ...
Unpacking libx11-data (2:1.6.2-3+deb8u1) ...
Selecting previously unselected package libx11-6:amd64.
Preparing to unpack .../libx11-6_2%3a1.6.2-3+deb8u1_amd64.deb ...
Unpacking libx11-6:amd64 (2:1.6.2-3+deb8u1) ...
Selecting previously unselected package libxext6:amd64.
Preparing to unpack .../libxext6_2%3a1.3.3-1_amd64.deb ...
Unpacking libxext6:amd64 (2:1.3.3-1) ...
Selecting previously unselected package libxmuu1:amd64.
Preparing to unpack .../libxmuu1_2%3a1.1.2-1_amd64.deb ...
Unpacking libxmuu1:amd64 (2:1.1.2-1) ...
Selecting previously unselected package less.
Preparing to unpack .../archives/less_458-3_amd64.deb ...
Unpacking less (458-3) ...
Selecting previously unselected package openssh-client.
Preparing to unpack .../openssh-client_1%3a6.7p1-5+deb8u4_amd64.deb ...
Unpacking openssh-client (1:6.7p1-5+deb8u4) ...
Selecting previously unselected package liberror-perl.
Preparing to unpack .../liberror-perl_0.17-1.1_all.deb ...
Unpacking liberror-perl (0.17-1.1) ...
Selecting previously unselected package git-man.
Preparing to unpack .../git-man_1%3a2.1.4-2.1+deb8u6_all.deb ...
Unpacking git-man (1:2.1.4-2.1+deb8u6) ...
Selecting previously unselected package git.
Preparing to unpack .../git_1%3a2.1.4-2.1+deb8u6_amd64.deb ...
Unpacking git (1:2.1.4-2.1+deb8u6) ...
Selecting previously unselected package git-core.
Preparing to unpack .../git-core_1%3a2.1.4-2.1+deb8u6_all.deb ...
Unpacking git-core (1:2.1.4-2.1+deb8u6) ...
Selecting previously unselected package git-ftp.
Preparing to unpack .../git-ftp_0.9.0-1_all.deb ...
Unpacking git-ftp (0.9.0-1) ...
Selecting previously unselected package rsync.
Preparing to unpack .../rsync_3.1.1-3+deb8u1_amd64.deb ...
Unpacking rsync (3.1.1-3+deb8u1) ...
Selecting previously unselected package xauth.
Preparing to unpack .../xauth_1%3a1.0.9-1_amd64.deb ...
Unpacking xauth (1:1.0.9-1) ...
Processing triggers for systemd (215-17+deb8u7) ...
Setting up libpopt0:amd64 (1.16-10) ...
Setting up libcurl3-gnutls:amd64 (7.38.0-4+deb8u11) ...
Setting up libexpat1:amd64 (2.1.0-6+deb8u4) ...
Setting up libxau6:amd64 (1:1.0.8-1) ...
Setting up libxdmcp6:amd64 (1:1.1.1-1+b1) ...
Setting up libxcb1:amd64 (1.10-3+b1) ...
Setting up libx11-data (2:1.6.2-3+deb8u1) ...
Setting up libx11-6:amd64 (2:1.6.2-3+deb8u1) ...
Setting up libxext6:amd64 (2:1.3.3-1) ...
Setting up libxmuu1:amd64 (2:1.1.2-1) ...
Setting up less (458-3) ...
debconf: unable to initialize frontend: Dialog
debconf: (TERM is not set, so the dialog frontend is not usable.)
debconf: falling back to frontend: Readline
Setting up openssh-client (1:6.7p1-5+deb8u4) ...
Setting up liberror-perl (0.17-1.1) ...
Setting up git-man (1:2.1.4-2.1+deb8u6) ...
Setting up git (1:2.1.4-2.1+deb8u6) ...
Setting up git-core (1:2.1.4-2.1+deb8u6) ...
Setting up git-ftp (0.9.0-1) ...
Setting up rsync (3.1.1-3+deb8u1) ...
invoke-rc.d: policy-rc.d denied execution of restart.
Setting up xauth (1:1.0.9-1) ...
Processing triggers for libc-bin (2.19-18+deb8u10) ...
Processing triggers for systemd (215-17+deb8u7) ...

+ git ftp push --user $SFTP_username --passwd $SFTP_password --verbose sftp://[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven
Wed Jul  4 23:38:18 UTC 2018: Host is '[host]'.
Wed Jul  4 23:38:18 UTC 2018: User is '[username]'.
Wed Jul  4 23:38:18 UTC 2018: Password is set.
Wed Jul  4 23:38:18 UTC 2018: Added missing trailing / in path.
Wed Jul  4 23:38:18 UTC 2018: Path is '[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven/'.
Wed Jul  4 23:38:18 UTC 2018: Syncroot is ''.
Wed Jul  4 23:38:18 UTC 2018: CACert is ''.
Wed Jul  4 23:38:18 UTC 2018: Insecure is ''.
Wed Jul  4 23:38:18 UTC 2018: Retrieving last commit from sftp://[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven/.

curl: (2) Failure establishing ssh session
Wed Jul  4 23:38:18 UTC 2018: fatal: Could not get last commit. Network down? Wrong URL? Use 'git ftp init' for the inital push., exiting...

Searching for test report files in directories named [test-results, failsafe-reports, test-reports, surefire-reports] down to a depth of 4
Finished scanning for test reports. Found 0 test report files.
Merged test suites, total number tests is 0, with 0 failures and 0 errors.

成功 — 2018 年 5 月 14 日

+ umask 000

+ GIT_LFS_SKIP_SMUDGE=1 git clone --branch="master" --depth 50 [auth token] $BUILD_DIR ; git reset --hard cfd69a33f41add0a81bc04a2bf81e0c0abc1a0b9 ; git remote set-url origin [git path]
Cloning into '/opt/atlassian/pipelines/agent/build'...
HEAD is now at cfd69a3 Retrying blockquote link text color update

+ chmod 777 $BUILD_DIR

+ apt-get update
Ign http://deb.debian.org jessie InRelease
Get:1 http://deb.debian.org jessie-updates InRelease [145 kB]
Get:2 http://security.debian.org jessie/updates InRelease [94.4 kB]
Get:3 http://deb.debian.org jessie Release.gpg [2434 B]
Get:4 http://deb.debian.org jessie Release [148 kB]
Get:5 http://deb.debian.org jessie-updates/main amd64 Packages [23.0 kB]
Get:6 http://security.debian.org jessie/updates/main amd64 Packages [650 kB]
Get:7 http://deb.debian.org jessie/main amd64 Packages [9064 kB]
Fetched 10.1 MB in 5s (1705 kB/s)
Reading package lists...

+ apt-get -qq install git-ftp
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package libpopt0:amd64.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 12703 files and directories currently installed.)
Preparing to unpack .../libpopt0_1.16-10_amd64.deb ...
Unpacking libpopt0:amd64 (1.16-10) ...
Selecting previously unselected package libcurl3-gnutls:amd64.
Preparing to unpack .../libcurl3-gnutls_7.38.0-4+deb8u10_amd64.deb ...
Unpacking libcurl3-gnutls:amd64 (7.38.0-4+deb8u10) ...
Selecting previously unselected package libexpat1:amd64.
Preparing to unpack .../libexpat1_2.1.0-6+deb8u4_amd64.deb ...
Unpacking libexpat1:amd64 (2.1.0-6+deb8u4) ...
Selecting previously unselected package libxau6:amd64.
Preparing to unpack .../libxau6_1%3a1.0.8-1_amd64.deb ...
Unpacking libxau6:amd64 (1:1.0.8-1) ...
Selecting previously unselected package libxdmcp6:amd64.
Preparing to unpack .../libxdmcp6_1%3a1.1.1-1+b1_amd64.deb ...
Unpacking libxdmcp6:amd64 (1:1.1.1-1+b1) ...
Selecting previously unselected package libxcb1:amd64.
Preparing to unpack .../libxcb1_1.10-3+b1_amd64.deb ...
Unpacking libxcb1:amd64 (1.10-3+b1) ...
Selecting previously unselected package libx11-data.
Preparing to unpack .../libx11-data_2%3a1.6.2-3+deb8u1_all.deb ...
Unpacking libx11-data (2:1.6.2-3+deb8u1) ...
Selecting previously unselected package libx11-6:amd64.
Preparing to unpack .../libx11-6_2%3a1.6.2-3+deb8u1_amd64.deb ...
Unpacking libx11-6:amd64 (2:1.6.2-3+deb8u1) ...
Selecting previously unselected package libxext6:amd64.
Preparing to unpack .../libxext6_2%3a1.3.3-1_amd64.deb ...
Unpacking libxext6:amd64 (2:1.3.3-1) ...
Selecting previously unselected package libxmuu1:amd64.
Preparing to unpack .../libxmuu1_2%3a1.1.2-1_amd64.deb ...
Unpacking libxmuu1:amd64 (2:1.1.2-1) ...
Selecting previously unselected package less.
Preparing to unpack .../archives/less_458-3_amd64.deb ...
Unpacking less (458-3) ...
Selecting previously unselected package openssh-client.
Preparing to unpack .../openssh-client_1%3a6.7p1-5+deb8u4_amd64.deb ...
Unpacking openssh-client (1:6.7p1-5+deb8u4) ...
Selecting previously unselected package liberror-perl.
Preparing to unpack .../liberror-perl_0.17-1.1_all.deb ...
Unpacking liberror-perl (0.17-1.1) ...
Selecting previously unselected package git-man.
Preparing to unpack .../git-man_1%3a2.1.4-2.1+deb8u5_all.deb ...
Unpacking git-man (1:2.1.4-2.1+deb8u5) ...
Selecting previously unselected package git.
Preparing to unpack .../git_1%3a2.1.4-2.1+deb8u5_amd64.deb ...
Unpacking git (1:2.1.4-2.1+deb8u5) ...
Selecting previously unselected package git-core.
Preparing to unpack .../git-core_1%3a2.1.4-2.1+deb8u5_all.deb ...
Unpacking git-core (1:2.1.4-2.1+deb8u5) ...
Selecting previously unselected package git-ftp.
Preparing to unpack .../git-ftp_0.9.0-1_all.deb ...
Unpacking git-ftp (0.9.0-1) ...
Selecting previously unselected package rsync.
Preparing to unpack .../rsync_3.1.1-3+deb8u1_amd64.deb ...
Unpacking rsync (3.1.1-3+deb8u1) ...
Selecting previously unselected package xauth.
Preparing to unpack .../xauth_1%3a1.0.9-1_amd64.deb ...
Unpacking xauth (1:1.0.9-1) ...
Processing triggers for systemd (215-17+deb8u7) ...
Setting up libpopt0:amd64 (1.16-10) ...
Setting up libcurl3-gnutls:amd64 (7.38.0-4+deb8u10) ...
Setting up libexpat1:amd64 (2.1.0-6+deb8u4) ...
Setting up libxau6:amd64 (1:1.0.8-1) ...
Setting up libxdmcp6:amd64 (1:1.1.1-1+b1) ...
Setting up libxcb1:amd64 (1.10-3+b1) ...
Setting up libx11-data (2:1.6.2-3+deb8u1) ...
Setting up libx11-6:amd64 (2:1.6.2-3+deb8u1) ...
Setting up libxext6:amd64 (2:1.3.3-1) ...
Setting up libxmuu1:amd64 (2:1.1.2-1) ...
Setting up less (458-3) ...
debconf: unable to initialize frontend: Dialog
debconf: (TERM is not set, so the dialog frontend is not usable.)
debconf: falling back to frontend: Readline
Setting up openssh-client (1:6.7p1-5+deb8u4) ...
Setting up liberror-perl (0.17-1.1) ...
Setting up git-man (1:2.1.4-2.1+deb8u5) ...
Setting up git (1:2.1.4-2.1+deb8u5) ...
Setting up git-core (1:2.1.4-2.1+deb8u5) ...
Setting up git-ftp (0.9.0-1) ...
Setting up rsync (3.1.1-3+deb8u1) ...
invoke-rc.d: policy-rc.d denied execution of restart.
Setting up xauth (1:1.0.9-1) ...
Processing triggers for libc-bin (2.19-18+deb8u10) ...
Processing triggers for systemd (215-17+deb8u7) ...

+ git ftp push --user $SFTP_username --passwd $SFTP_password --verbose sftp://[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven
Mon May 14 15:13:51 UTC 2018: Host is '[host]'.
Mon May 14 15:13:51 UTC 2018: User is '[username]'.
Mon May 14 15:13:51 UTC 2018: Password is set.
Mon May 14 15:13:51 UTC 2018: Added missing trailing / in path.
Mon May 14 15:13:51 UTC 2018: Path is '[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven/'.
Mon May 14 15:13:51 UTC 2018: Syncroot is ''.
Mon May 14 15:13:51 UTC 2018: CACert is ''.
Mon May 14 15:13:51 UTC 2018: Insecure is ''.
Mon May 14 15:13:51 UTC 2018: Retrieving last commit from sftp://[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven/.

######################################################################## 100.0%
Mon May 14 15:13:52 UTC 2018: Last deployed SHA1 for [path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven/ is 42105ae36f479314d0e2d89a97090125e6dea7ab.
Mon May 14 15:13:52 UTC 2018: Having changed files.
Mon May 14 15:13:52 UTC 2018: There are 1 files to sync:
Mon May 14 15:13:52 UTC 2018: [1 of 1] Buffered for upload 'style.css'.
Mon May 14 15:13:52 UTC 2018: Uploading ...

######################################################################## 100.0%
Mon May 14 15:13:52 UTC 2018: Uploading commit log to sftp://[path]/wp-content/plugins/jetpack/modules/minileven/theme/pub/minileven/.git-ftp.log.

######################################################################## 100.0%
Mon May 14 15:13:52 UTC 2018: Last deployment changed to cfd69a33f41add0a81bc04a2bf81e0c0abc1a0b9.

Searching for test report files in directories named [test-results, failsafe-reports, test-reports, surefire-reports] down to a depth of 4
Finished scanning for test reports. Found 0 test report files.
Merged test suites, total number tests is 0, with 0 failures and 0 errors.
4

0 回答 0