File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -569,10 +569,11 @@ private function generate_ssh_command( $bits, $wp_command ) {
569569 WP_CLI ::debug ( 'SSH ' . $ bit . ': ' . $ bits [ $ bit ], 'bootstrap ' );
570570 }
571571
572- $ is_tty = function_exists ( 'posix_isatty ' ) && posix_isatty ( STDOUT );
573- $ docker_compose_cmd = ! empty ( Process::create ( Utils \esc_cmd ( '/usr/bin/env docker compose %s ' , 'version ' ) )->run ()->stdout )
574- ? 'docker compose '
575- : 'docker-compose ' ;
572+ $ is_tty = function_exists ( 'posix_isatty ' ) && posix_isatty ( STDOUT );
573+ $ docker_compose_v2_version_cmd = Utils \esc_cmd ( Utils \force_env_on_nix_systems ( 'docker ' ) . ' compose %s ' , 'version ' );
574+ $ docker_compose_cmd = ! empty ( Process::create ( $ docker_compose_v2_version_cmd )->run ()->stdout )
575+ ? 'docker compose '
576+ : 'docker-compose ' ;
576577
577578 if ( 'docker ' === $ bits ['scheme ' ] ) {
578579 $ command = 'docker exec %s%s%s sh -c %s ' ;
You can’t perform that action at this time.
0 commit comments