hestiacp / hestiacp

Hestia Control Panel | A lightweight and powerful control panel for the modern web.
https://hestiacp.com
GNU General Public License v3.0
3.31k stars 675 forks source link

[Bug] Unable to update WP CLI with out confirmation #4471

Closed weikib closed 1 month ago

weikib commented 1 month ago

Describe the bug

First of all, thank you for your work and for making update after update a more stable and solid panel without losing the focus on the technical user.

I have installed v1.9.0~alpha on 3 machines with different pecualities, to be able to debug and test the new features.

When using the new wordpress cli installer, from arm oracle always free , I get this message:

On other amd64 machines, both existing and installing from scratch (following the steps of https://hestiacp.com/docs/contributing/testing.html ) it works correctly, except for some details. (php version 8.2 on some machines.

PHP Notice:  You have version 2.8.1. Would you like to update to 2.10.0? [y/n] Interrupt
Error: cmd exited with errors in /usr/local/hestia/web/src/app/System/HestiaApp.php on line 46

In HestiaApp.php line 48:

  You have version 2.8.1. Would you like to update to 2.10.0? [y/n] Interrupt  
  Error: cmd exited with errors                                                

Tell us how to replicate the bug

  1. Machine with oracle alwaysfree
  2. server previously installed
  3. Upgrade to alpha following tutorial
  4. Try to install using cli
  5. It stays running and when you press ctrl c you get that message.

Which components are affected by this bug?

Control Panel Command Line Interface, Control Panel Installation or Upgrade

Hestia Control Panel Version

v1.9.0~alpha

Operating system

Ubuntu 22.04

Log capture

No response

jaapmarcus commented 1 month ago

https://github.com/hestiacp/hestiacp/blob/82d063ea9d7046812bb43466ceaa66a8e6292726/web/src/app/System/HestiaApp.php#L144-L155

Probably caused by $this->runUser("v-run-cli-cmd", [$wp, "cli", "update"]);

jaapmarcus commented 1 month ago

Can confirm the issue

jaapmarcus commented 1 month ago

Please try to edit the file in the PR on your local machine

https://github.com/hestiacp/hestiacp/pull/4472

If it is an test server: v-update-sys-hestiacp-git hestiacp fix-update-warnign-wpcli

Will do the trick aswell

weikib commented 1 month ago

I confirm, #4472 solves it.

I will keep testing and report back on anything I see.

Solved.