diff --git a/src/Shell_Command.php b/src/Shell_Command.php index 24873c6..069e746 100644 --- a/src/Shell_Command.php +++ b/src/Shell_Command.php @@ -105,9 +105,9 @@ public function __invoke( $args, $assoc_args ) { $tty = get_flag_value( $assoc_args, 'skip-tty' ) ? '-T' : ''; if ( $command ) { - EE::exec( "docker-compose exec $tty $user_string $service $shell -c \"$command\"", true, true, [], true ); + EE::exec( \EE_DOCKER::docker_compose_with_custom() . " exec $tty $user_string $service $shell -c \"$command\"", true, true, [], true ); } else { - $this->run( "docker-compose exec $user_string $service $shell" ); + $this->run( \EE_DOCKER::docker_compose_with_custom() . " exec $user_string $service $shell" ); } EE\Utils\delem_log( 'ee shell end' ); } @@ -146,7 +146,7 @@ private function run( $cmd, $descriptors = null ) { */ private function check_shell_available( $shell_container, $site ) { - $launch = EE::launch( 'docker-compose config --services' ); + $launch = EE::launch( \EE_DOCKER::docker_compose_with_custom() . ' config --services' ); $services = explode( PHP_EOL, trim( $launch->stdout ) ); if ( in_array( $shell_container, $services, true ) ) { return; @@ -165,7 +165,7 @@ private function check_shell_available( $shell_container, $site ) { * @return bool Success. */ private function check_user_available( $user, $shell_container ) { - $check_command = sprintf( "docker-compose exec --user='%s' %s bash -c 'exit'", $user, $shell_container ); + $check_command = sprintf( \EE_DOCKER::docker_compose_with_custom() . " exec --user='%s' %s bash -c 'exit'", $user, $shell_container ); if ( EE::exec( $check_command ) ) { return true;