WordPress.org

Make WordPress Core

Opened 8 years ago

Closed 8 years ago

#27265 closed defect (bug) (fixed)

trivial patch to make update form select the "SSH" radio button when FS_METHOD=='ssh2'

Reported by: jnielsendotnet Owned by: dd32
Milestone: 3.9 Priority: normal
Severity: normal Version: 3.8.1
Component: Filesystem API Keywords: commit has-patch
Focuses: Cc:

Description

Possibly related to #17960.

I am trying to script a configuration where WordPress can update itself and install/update plugins via SSH. All tests are on a freshly installed WordPress with a new database. I go through the 5-minute install screen then to updates->reinstall now.

It fails in two different ways depending on the value of FS_METHOD in wp-config.php.

If I set FS_METHOD to "ssh", the form selects the right button but the first update/reinstall doesn't work (it never even tries an SSH connection). If I set FS_METHOD to "ssh2", the form does not select the right button but (if I select it manually) the first update/reinstall does work.

I am attaching a trivial patch that changes 'ssh' to 'ssh2' in two comments and one comparison in wp-admin/includes/file.php. With this patch everything works as expected with default configured values.

Attachments (1)

file.php.patch (1.6 KB) - added by jnielsendotnet 8 years ago.

Download all attachments as: .zip

Change History (4)

#1 @dd32
8 years ago

  • Keywords commit has-patch added

Looks good. The transport name is indeed 'ssh2' rather than 'ssh'.

#2 @dd32
8 years ago

  • Milestone changed from Awaiting Review to 3.9

#3 @dd32
8 years ago

  • Owner set to dd32
  • Resolution set to fixed
  • Status changed from new to closed

In 27546:

WP_Filesystem: Update request_filesystem_credentials() to handle the correct ssh value of FS_METHOD. Props jnielsendotnet. Fixes #27265

Note: See TracTickets for help on using tickets.