Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Victor Remmerswaal 2 posts 72 karma points
    Apr 28, 2020 @ 13:37
    Victor Remmerswaal
    0

    Image Cropper doesn't seem to work with Umbraco 8 and Azure Blob storage

    Hi,

    Forgive me if there is already a ready answer to this. Maybe my Google-fu is insufficient here.

    We've got an Umbraco 8.4.0 instance running on an Azure App service with the media saved in the corresponding blob storage account. And it is able to write and read media to and from that blob storage.

    However, whenever we get a media item in a razor view and call .GetCropUrl("cropAlias") it won't give us a cropped version. It will return an url which looks like the correct crop should result from requesting that URL, but it's just the full res image when you get it.

    I already tried to add the ImageProcessor.Web.Plugins.AzureBlobCache NuGet package, but that didn't seem to do the trick even when it was configured to talk to the blob storage the media is saved in.

    Can anyone help me with this? We desperately need this to work so cropped versions of images can be loaded for mobile users.

    Anyway. thanks

    EDIT: It seems like Image processor isn't able to access the blob storage image I get the following error in the trace log:

    {"@t":"2020-04-28T13:43:22.5670523Z","@mt":"Exception","@l":"Error","@x":"ImageProcessor.Common.Exceptions.ImageProcessingException: ProcessImageAsync 609 : No image exists at [URLTOOURBLOBSTORAGE]/media/q4tpe3gn/2.png","SourceContext":"ImageProcessor.Web.HttpModules.ImageProcessingModule","ProcessId":17368,"ProcessName":"w3wp","ThreadId":158,"AppDomainId":14,"AppDomainAppId":"LMW3SVC23ROOT","MachineName":"[REDACTED_MACHINE_NAME]","Log4NetLevel":"ERROR"}
    

    EDIT 2: (Rubber ducky programming here) I've set the access level of the blob storage to Blob (aka anonymous read but no write) and now it seems to work. However we'd like to set it to private so all media requests have to go through Umbraco.

    We've set the connection string in all the image processor configs the same as the AzureBlobFileSystem.ConnectionString:media connection string. Still it doesn't work when the blob storage is set to private.

  • Yakov Lebski 550 posts 2114 karma points
    Apr 28, 2020 @ 14:50
    Yakov Lebski
    0

    check what your container is public

Please Sign in or register to post replies

Write your reply to:

Draft