How to install WP-CLI on Directadmin Centos 8
Install WP-CLI
WP-CLI wordt niet voorgeïnstalleerd op je hostingpakket. Daar zijn eigenlijk twee simpele redenen voor. Niet iedereen met een hostingpakket wil per se WordPress gebruiken. Wel WordPress installeren betekent daarnaast niet dat iemand ook meteen WP-CLI wil. Gelukkig is zelf WP-CLI installeren zo gebeurd en daarna ook makkelijk bij te werken wanneer nodig.
- WP-CLI is available as a PHP Archive file (
.phar). You can download it using eitherwgetorcurlcommands:curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
Orwget https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar - You need to make this
.pharfile executable and move it to/usr/local/binso that it can be run directly:
chmod +x wp-cli.phar sudo mv wp-cli.phar /usr/local/bin/wp - Install the JSON extension for PHP 7. You will need this extension in order to use the WP-CLI.
sudo dnf install php-json - Check if it is installed properly:
wp –info