Last active
April 17, 2018 00:57
-
-
Save nford/8700b6316f166fd7d09a6220fb4b8270 to your computer and use it in GitHub Desktop.
Install ImageMagic and Imagick on Ubuntu 14.04
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/env sh | |
#This was done for a Bitnami Wordpress instance that was producing a lot of wand related errors | |
#and then supported formats errors in Apache PHP | |
sudo apt update | |
sudo apt install libmagickwand-dev imagemagick -y | |
sudo ln -s /usr/lib/x86_64-linux-gnu/pkgconfig/ImageMagick.pc /usr/lib/pkgconfig/ImageMagick.pc | |
sudo ln -s /usr/lib/x86_64-linux-gnu/pkgconfig/MagickWand.pc /usr/lib/pkgconfig/MagickWand.pc | |
sudo pecl install imagick | |
sudo sed -i 's/;extension=imagick.so/extension=imagick.so/' /opt/bitnami/php/etc/php.ini | |
# You will probably have to add these lines (adjust paths as needed) to /opt/bitnami/scripts/setenv.sh : | |
##### APACHE ENV ##### | |
#MAGICK_HOME=/usr/lib/x86_64-linux-gnu/ImageMagick-6.7.7/ | |
#export MAGICK_HOME | |
#MAGICK_CONFIGURE_PATH=/etc/ImageMagick/ | |
#export MAGICK_CONFIGURE_PATH | |
#MAGICK_CODER_MODULE_PATH=/usr/lib/x86_64-linux-gnu/ImageMagick-6.7.7/modules-Q16/coders | |
#export MAGICK_CODER_MODULE_PATH | |
sudo /opt/bitnami/ctlscript.sh restart php-fpm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment