Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closes #3924: Install ImageMagick by default on Pantheon sites. #3925

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions az_quickstart.install
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ function az_quickstart_install() {
$extra_modules = [
'pantheon_advanced_page_cache',
'environment_indicator',
'imagemagick',
];
}
else {
Expand Down Expand Up @@ -217,3 +218,19 @@ function az_quickstart_update_1020901(&$sandbox) {
$sandbox['#finished'] = empty($sandbox['max']) ? 1 : $sandbox['progress'] / $sandbox['max'];
return t('Updated langcode on %count menu links.', ['%count' => $sandbox['progress']]);
}

/**
* Ensure Pantheon sites have the imagemagick module installed.
*/
function az_quickstart_update_1021101() {
if (defined('PANTHEON_ENVIRONMENT')) {
try {
\Drupal::service('module_installer')->install(['imagemagick']);
}
catch (MissingDependencyException $e) {
return t('ImageMagick module not available to install.');
}

return t('ImageMagick module installed.');
}
}
Loading