Open MartiniHenry1988 opened 8 years ago
Having a very similar issue where the stores seem to be completely ignored and only the original is being uploaded.
var small = new FS.Store.GridFS('small',{
transformWrite: function(fileObj, readStream, writeStream) {
gm(readStream, fileObj.name).resize('320', '320').stream().pipe(writeStream);
}
});
var medium = new FS.Store.GridFS('medium',{
transformWrite: function(fileObj, readStream, writeStream) {
gm(readStream, fileObj.name).resize('768', '768').stream().pipe(writeStream);
}
});
var full = new FS.Store.GridFS('full',{
transformWrite: function(fileObj, readStream, writeStream) {
gm(readStream, fileObj.name).resize('1280', '1280').stream().pipe(writeStream);
}
});
Images = new FS.Collection("images", {
stores: [small, medium, full],
filter: {
allow: {
contentTypes: ['image/*']
}
}
});
Locally everything work perfect... only when I deploy the issue happens.
Deploying to Digital Ocean - Ubuntu 14.04.3 x64 and graphicksmagick is installed there also.
Same solution as @luisreyes. It's work on VPS OVH - ubuntu 14.04.3 x46
I am trying to upload Image and keep its thumbnail as well.
I am using Meteor CollectionFS.
Here is my code:
The above code is perfectly uploading the original image to
/uploads
directory, but it is not resizing the image. Means it uploads the original image to uploads/thumbs as well. I want a resized image to/uploads/thumbs
directory and original Image to/uploads
directory. What am I missing here? Why is an original image uploading to/uploads/thumbs
directory?graphicmagick
is also installed on my Ubuntu 14.04