ImageSharp Not Resizing Images loaded from another server(virtual directory)

I’m using Umbraco 13 ,ImageSharp is not resizing images(loaded from virtual custom directory from another server).For images inside project’s wwwroot folder ,ImageSharp works fine while changing query parameters.Any work around for this?

Here is code sample , how I’m rendering virtual images

var virDirImages = new FileServerOptions
{
    FileProvider = new PhysicalFileProvider(@"\\server1\projectname\wwwroot\images"),
    RequestPath = new PathString("/images"),
    EnableDirectoryBrowsing = false
};

app.UseFileServer(virDirImages);
app.UseImageSharp();
app.UseStaticFiles();

This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/114312-imagesharp-not-resizing-images-loaded-from-another-server-virtual-directory

I am having this same issue with the images hosted on azure storage (File shares). Please see the post here https://forum.umbraco.com/t/imagesharp-not-resizing-images-stored-outside-umbraco-media-folder-in-umbraco-13/3933.