wp-media / wp-rocket-cli

WP CLI interface for the WP Rocket plugin

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Installation method

jmslbam opened this issue · comments

Please re-consider loading it as a regular plugin or merge it with the WP Rocket plugin itself.

Not every server is fitted to use the WP-CLI package installer.

E.g. No composer on the server, or composer misconfigured, or server is managed by hosting that doesn't allow installing it.

In my case (and other WP-CLI users) installing a WP-CLI package results in Composer memory errors.

[xyz@foo public_html]$ wp package install wp-media/wp-rocket-cli
Installing package wp-media/wp-rocket-cli (dev-master)
Updating /home/xyz/.wp-cli/packages/composer.json to require the package...
Using Composer to install the package...
---
Loading composer repositories with package information
Updating dependencies
Resolving dependencies through SAT
Looking at all rules.

Dependency resolution completed in 0.018 seconds
Analyzed 1839 packages to resolve dependencies
Analyzed 74806 rules to resolve dependencies
Package operations: 1 install, 0 updates, 0 removals
Installs: wp-media/wp-rocket-cli:dev-trunk 4499a10
 - Installing wp-media/wp-rocket-cli (dev-trunk 4499a10)
PHP Warning:  proc_open(): fork failed - Cannot allocate memory in phar:///usr/local/bin/wp/vendor/symfony/process/Process.php on line 285
PHP Warning:  proc_open(): fork failed - Cannot allocate memory in phar:///usr/local/bin/wp/vendor/symfony/process/Process.php on line 285
PHP Warning:  proc_open(): fork failed - Cannot allocate memory in phar:///usr/local/bin/wp/vendor/symfony/process/Process.php on line 285
PHP Warning:  proc_open(): fork failed - Cannot allocate memory in phar:///usr/local/bin/wp/vendor/symfony/process/Process.php on line 285
Warning: Unable to launch a new process.
---
Error: Package installation failed.
Reverted composer.json.

So now I need to install it by:

  1. Adding the plugin header back in manually 4fef271 and re-upload it.
  2. Or include the code in my project myself.

Did it broke the loading of the plugin to leave the plugin header in? When it was installed via the WP-CLI package manager?

Kinds regards,

Jaime

I was able to install with wp package install wp-media/wp-rocket-cli:@stable

Yeah, some probally will be able to install it. I could install it on my local developement setup.

But not on my webserver because of the architecture of user permission settings / memory assignment etc.

It's more that this method of installing doesn't have a 100% succes-rate which makes manually changing the code a overhead, which minimize the amount of people that will be using it. It's a treshold thrown-up which doensn't have to be there.

Making me go through these extra loops doesn't make it more friendly.

The host comes w/ WP-CLI pre-installed but doesn't allow WP-CLI packages to be installed via WP-CLI?