Make WordPress Core

Opened 3 years ago

Last modified 23 months ago

#55466 new enhancement

Build Tools: create Docker test environment that use non-direct filesystems

Reported by: afragen's profile afragen Owned by:
Milestone: Future Release Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords: dev-feedback
Focuses: Cc:

Description

Recently when writing a PR for #51170, @costdev and I, mostly Colin as I let him do this, had a somewhat difficult time setting up a testing environment that used FTPext or FTPsockets.

It would be awesome if this could be built into a Docker image for testing with WordPress-develop.

If this can be done it might be worthwhile to setup environments for the other file system methods too.

Change History (8)

#1 @costdev
3 years ago

This was what I used to get ftpext/ftpsockets working:

  • An FTP server: I used vsftpd on Ubuntu.
  • FTP write permissions: This involves uncommenting # write_enable=YES in /etc/vsftpd.conf.
  • Write access to the necessary folders (i.e. Site Health > Info > File system permissions).
  • A new user for FTP:
    sudo useradd FTP_USER
    sudo passwd FTP_USER
    (enter password):
    
  • Entries in wp-config.php:
    define( 'FS_METHOD', 'ftpext' ); // Or 'ftpsockets'.
    
    define( 'FTP_BASE', '/var/www/html/wordpress-develop/src/' );
    define( 'FTP_USER', 'FTP_USER' );
    define( 'FTP_PASS', 'password' );
    define( 'FTP_HOST', 'localhost' );
    define( 'FTP_SSL', false );
    

While the steps above may seem straightforward, note that despite my experience using FTP, the learning curve wasn't as straightforward as the above might imply.

For less experienced contributors, being able to switch between filesystems easily would be quite beneficial.

  • Numerous tickets have needed testing on multiple filesystems and many contributors may not be comfortable with the learning curve/debugging journey to get things working smoothly.
  • This means that a small number of contributors are available to test on multiple filesystems.
  • Reaching out to the hosting community has been great for enhancement/new feature requests, but often there needs to be a reasonable MVP before testing can be done. Spinning up an environment that uses ftpext, for example, would allow for quick testing of incremental improvements.
  • Testing must also be done to reproduce bugs on a certain WP_Filesystem_* - a more common day-to-day activity for contributors. Quickly spinning up in a different filesystem means the Test Team can quickly and confidently reproduce bugs/test patches during scrubs.
Last edited 3 years ago by costdev (previous) (diff)

This ticket was mentioned in Slack in #core by afragen. View the logs.


3 years ago

#3 @afragen
3 years ago

  • Milestone changed from Awaiting Review to 6.1

This ticket was mentioned in Slack in #core by afragen. View the logs.


3 years ago

This ticket was mentioned in Slack in #core-auto-updates by afragen. View the logs.


2 years ago

This ticket was mentioned in Slack in #core-auto-updates by afragen. View the logs.


2 years ago

#7 @desrosj
2 years ago

  • Milestone changed from 6.1 to Future Release

I'm going to kick this one out to Future Release. While Build/Test tool changes can be committed at any time during the release and I hate to push this one off, there hasn't been any movement in a few months.

I also would ideally like this to be fixed directly in the Docker images if possible. A PR there for testing would be a good starting point.

#8 @costdev
23 months ago

Woops I thought I'd posted this.

I opened an issue on the repository above to request some help in putting a PR together to address this.

Note: See TracTickets for help on using tickets.