[LINUX] I got an error when I ran composer global require laravel / installer

Development environment

Host OS: Windows10 home Guest OS: WSL2 Ubuntu 20.04 php7.4.7

Error that occurred

When I run composer global require laravel / installer, I get the following error:

 Problem 1
    - Installation request for laravel/installer ^3.1 -> satisfiable by laravel/installer[v3.1.0].
    - laravel/installer v3.1.0 requires ext-zip * -> the requested PHP extension zip is missing from your system.

Apparently the php module zip is not installed. But zip is already installed

which zip

/usr/bin/zip

I thought ... but I didn't specify the version when installing the module.

Therefore, specify the version and install again.

sudo apt install php7.4-zip

Check if the module has been added

php -m

[PHP Modules]
bcmath
.
.
(abridgement)
.
.
zip
zlib

It is installed without any problem. When the command was executed again in this state, it could be executed without any problem.

Summary

Don't forget to specify the version when installing the php module.

Recommended Posts

I got an error when I ran composer global require laravel / installer
I got an error when I ran meteor add accounts-password and got hooked
I got an error when saving with OpenCV
I got an error when using Tensorboard with Pytorch
When I get an error with PyInstaller
I got an error when trying to install Xgboost and its solution
I got an error when trying to run Hello World in Go language
I got an error when I put opencv in python3 with Raspberry Pi [Remedy]
Linux Ubuntu16.04 I got a little scary error when I ran a command using sudo
I got an error that Python couldn't read settings.ini
I get an error when I put opencv in pyautoGUI
I get an error when trying meinheld + WebSocket + mongodb
psql: I ran into an error with an invalid option --'''.
I got an error when pip install pandas on Mac, so I dealt with it
I got an error when pip install tweepy on macOS Sierra, so I dealt with it
When I installed python on macOS and used it, I got an error when I put an https connection
I got a Value Error when using JUMAN ++ with PyKNP
I got an error in vim and zsh in Python 3.7 series
I got an error when I tried to process luigi in parallel on windows, but the solution
I got an SSL Error when I installed Anaconda in a new environment, so I solved it (Windows10, Anaconda3-2019.10)
I got an AttributeError when mocking the open method in python
When I get an error with Pylint in Atom on Windows
I get an error when trying to install maec 4.0.1.0 with pip
I got an SSL related error with pip install, so I solved it
I got an unfamiliar error in Django: TypeError: resolve () got an unexpected keyword argument'strict'