This article is a mirror article of machine translation, please click here to jump to the original article.

View: 6413|Reply: 2

Install the GD extension based on the Docker php:5.6.40-fpm image

[Copy link]
Posted on 11/27/2021 7:59:14 PM | | | |
Startup with docker is based onphp:5.6.40-fpmFor mirrored applications, php does not have GD extensions installed by default, so we need to install them manually.

The application command to start a php:5.6.40-fpm image is as follows:

Go to the container application and command as follows:

php:5.6.40-fpm 镜像的系统为:debian 9

Set up Debian Alibaba Cloud image source acceleration

backup


To set up an Alibaba Cloud image source, follow these commands:

Update the source and install the necessary plugins


Start installing the GD extension


After the installation is complete, you need to restart the container for the extension to take effect, with the following command:


Use php -m and phpinfo(); Check it out below:



Create a new test.php file, call the gd_info() method, and view the output, the file content is as follows:



array(13) { ["GD Version"]=> string(26) "bundled (2.1.0 compatible)" ["FreeType Support"]=> bool(true) ["FreeType Linkage"]=> string(13) "with freetype" ["T1Lib Support"]=> bool(false) ["GIF Read Support"]=> bool(true) ["GIF Create Support"]=> bool(true) ["JPEG Support"]=> bool(true) ["PNG Support"]=> bool(true) ["WBMP Support"]=> bool(true) ["XPM Support"]=> bool( false) ["XBM Support"]=> bool(true) ["WebP Support"]=> bool(false) ["JIS-mapped Japanese Font Support"]=> bool(false) }
Watermark the image through GD through the Discuz program test, as shown below:



(End)





Previous:The difference between Docker's save and export commands
Next:Install the Redis extension based on Docker php:5.6.40-fpm image
 Landlord| Posted on 11/27/2021 8:25:56 PM |
Install the Redis extension based on Docker php:5.6.40-fpm image
https://www.itsvse.com/thread-10176-1-1.html
 Landlord| Posted on 11/12/2023 4:04:59 PM |
Debian repository update prompts with a 404 error
https://www.itsvse.com/thread-10698-1-1.html
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com