ImageMagick works in controllers but “not available” in queues?
I've just about lost my mind trying to fix this one. I'm using ImageMagick in my controllers, and it's working okay. I've now tried to move some of those functions to a queued job, and it's now saying "ImageMagick module not available with this PHP installation."
Move them back, everything works again. Put them into a Job
, everything breaks.
I'm not sure what context I could supply, really. I'm importing Image and Imagick the same in both the controllers and the jobs:
use InterventionImageImageManagerStatic as Image;
use Imagick;
Image::configure(['driver' => 'imagick']);
Works fine in the controller (and helper functions), but dies here in jobs:
$preview = Image::make($file);
Identical code, aside from that. Is there any other info that could be of use?
laravel laravel-5 imagemagick imagick
|
show 3 more comments
I've just about lost my mind trying to fix this one. I'm using ImageMagick in my controllers, and it's working okay. I've now tried to move some of those functions to a queued job, and it's now saying "ImageMagick module not available with this PHP installation."
Move them back, everything works again. Put them into a Job
, everything breaks.
I'm not sure what context I could supply, really. I'm importing Image and Imagick the same in both the controllers and the jobs:
use InterventionImageImageManagerStatic as Image;
use Imagick;
Image::configure(['driver' => 'imagick']);
Works fine in the controller (and helper functions), but dies here in jobs:
$preview = Image::make($file);
Identical code, aside from that. Is there any other info that could be of use?
laravel laravel-5 imagemagick imagick
have u performed acomposer dump-autoload
andphp artisan queue:restart
– Leorent
Jan 2 at 6:26
I have - neither of those help.
– MitchEff
Jan 2 at 6:29
whats ur local setup containers or simple mamp/xamp ?
– Leorent
Jan 2 at 6:30
Standard MAMP set-up. phpinfo() shows ImageMagick installed and working - I'd maybe guess jobs run through terminal, while controllers don't or something?
– MitchEff
Jan 2 at 6:32
OS runsphp artisan schedule:run
behind the curtains, then everything its executed in php in background so that should not affect anything. try again withphp artisan queue:work --tries=1
this should show you the specific errors... or use database to log the failed jobs so u can check what is exactly failing...
– Leorent
Jan 2 at 6:38
|
show 3 more comments
I've just about lost my mind trying to fix this one. I'm using ImageMagick in my controllers, and it's working okay. I've now tried to move some of those functions to a queued job, and it's now saying "ImageMagick module not available with this PHP installation."
Move them back, everything works again. Put them into a Job
, everything breaks.
I'm not sure what context I could supply, really. I'm importing Image and Imagick the same in both the controllers and the jobs:
use InterventionImageImageManagerStatic as Image;
use Imagick;
Image::configure(['driver' => 'imagick']);
Works fine in the controller (and helper functions), but dies here in jobs:
$preview = Image::make($file);
Identical code, aside from that. Is there any other info that could be of use?
laravel laravel-5 imagemagick imagick
I've just about lost my mind trying to fix this one. I'm using ImageMagick in my controllers, and it's working okay. I've now tried to move some of those functions to a queued job, and it's now saying "ImageMagick module not available with this PHP installation."
Move them back, everything works again. Put them into a Job
, everything breaks.
I'm not sure what context I could supply, really. I'm importing Image and Imagick the same in both the controllers and the jobs:
use InterventionImageImageManagerStatic as Image;
use Imagick;
Image::configure(['driver' => 'imagick']);
Works fine in the controller (and helper functions), but dies here in jobs:
$preview = Image::make($file);
Identical code, aside from that. Is there any other info that could be of use?
laravel laravel-5 imagemagick imagick
laravel laravel-5 imagemagick imagick
asked Jan 2 at 6:23
MitchEffMitchEff
17819
17819
have u performed acomposer dump-autoload
andphp artisan queue:restart
– Leorent
Jan 2 at 6:26
I have - neither of those help.
– MitchEff
Jan 2 at 6:29
whats ur local setup containers or simple mamp/xamp ?
– Leorent
Jan 2 at 6:30
Standard MAMP set-up. phpinfo() shows ImageMagick installed and working - I'd maybe guess jobs run through terminal, while controllers don't or something?
– MitchEff
Jan 2 at 6:32
OS runsphp artisan schedule:run
behind the curtains, then everything its executed in php in background so that should not affect anything. try again withphp artisan queue:work --tries=1
this should show you the specific errors... or use database to log the failed jobs so u can check what is exactly failing...
– Leorent
Jan 2 at 6:38
|
show 3 more comments
have u performed acomposer dump-autoload
andphp artisan queue:restart
– Leorent
Jan 2 at 6:26
I have - neither of those help.
– MitchEff
Jan 2 at 6:29
whats ur local setup containers or simple mamp/xamp ?
– Leorent
Jan 2 at 6:30
Standard MAMP set-up. phpinfo() shows ImageMagick installed and working - I'd maybe guess jobs run through terminal, while controllers don't or something?
– MitchEff
Jan 2 at 6:32
OS runsphp artisan schedule:run
behind the curtains, then everything its executed in php in background so that should not affect anything. try again withphp artisan queue:work --tries=1
this should show you the specific errors... or use database to log the failed jobs so u can check what is exactly failing...
– Leorent
Jan 2 at 6:38
have u performed a
composer dump-autoload
and php artisan queue:restart
– Leorent
Jan 2 at 6:26
have u performed a
composer dump-autoload
and php artisan queue:restart
– Leorent
Jan 2 at 6:26
I have - neither of those help.
– MitchEff
Jan 2 at 6:29
I have - neither of those help.
– MitchEff
Jan 2 at 6:29
whats ur local setup containers or simple mamp/xamp ?
– Leorent
Jan 2 at 6:30
whats ur local setup containers or simple mamp/xamp ?
– Leorent
Jan 2 at 6:30
Standard MAMP set-up. phpinfo() shows ImageMagick installed and working - I'd maybe guess jobs run through terminal, while controllers don't or something?
– MitchEff
Jan 2 at 6:32
Standard MAMP set-up. phpinfo() shows ImageMagick installed and working - I'd maybe guess jobs run through terminal, while controllers don't or something?
– MitchEff
Jan 2 at 6:32
OS runs
php artisan schedule:run
behind the curtains, then everything its executed in php in background so that should not affect anything. try again with php artisan queue:work --tries=1
this should show you the specific errors... or use database to log the failed jobs so u can check what is exactly failing...– Leorent
Jan 2 at 6:38
OS runs
php artisan schedule:run
behind the curtains, then everything its executed in php in background so that should not affect anything. try again with php artisan queue:work --tries=1
this should show you the specific errors... or use database to log the failed jobs so u can check what is exactly failing...– Leorent
Jan 2 at 6:38
|
show 3 more comments
1 Answer
1
active
oldest
votes
You probably don't have extension=imagick.so
in the ini file being used by the PHP command line executable, but do have that in the ini file being used by the PHP webserver executable.
If you find what ini file is being used by doing php -i | grep ini
on the command line, you'll be see what ini file needs to be edited.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54002082%2fimagemagick-works-in-controllers-but-not-available-in-queues%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
You probably don't have extension=imagick.so
in the ini file being used by the PHP command line executable, but do have that in the ini file being used by the PHP webserver executable.
If you find what ini file is being used by doing php -i | grep ini
on the command line, you'll be see what ini file needs to be edited.
add a comment |
You probably don't have extension=imagick.so
in the ini file being used by the PHP command line executable, but do have that in the ini file being used by the PHP webserver executable.
If you find what ini file is being used by doing php -i | grep ini
on the command line, you'll be see what ini file needs to be edited.
add a comment |
You probably don't have extension=imagick.so
in the ini file being used by the PHP command line executable, but do have that in the ini file being used by the PHP webserver executable.
If you find what ini file is being used by doing php -i | grep ini
on the command line, you'll be see what ini file needs to be edited.
You probably don't have extension=imagick.so
in the ini file being used by the PHP command line executable, but do have that in the ini file being used by the PHP webserver executable.
If you find what ini file is being used by doing php -i | grep ini
on the command line, you'll be see what ini file needs to be edited.
answered Jan 6 at 16:16
DanackDanack
18.6k866101
18.6k866101
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54002082%2fimagemagick-works-in-controllers-but-not-available-in-queues%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
have u performed a
composer dump-autoload
andphp artisan queue:restart
– Leorent
Jan 2 at 6:26
I have - neither of those help.
– MitchEff
Jan 2 at 6:29
whats ur local setup containers or simple mamp/xamp ?
– Leorent
Jan 2 at 6:30
Standard MAMP set-up. phpinfo() shows ImageMagick installed and working - I'd maybe guess jobs run through terminal, while controllers don't or something?
– MitchEff
Jan 2 at 6:32
OS runs
php artisan schedule:run
behind the curtains, then everything its executed in php in background so that should not affect anything. try again withphp artisan queue:work --tries=1
this should show you the specific errors... or use database to log the failed jobs so u can check what is exactly failing...– Leorent
Jan 2 at 6:38