Digital Ocean Spaces To Use cdn

I’m trying to do the same, couldn’t find any resources on this. I found that when using AWS s3, the cdn endpoint is specified as the ‘baseURL’. but for s3 compatible services such as digital ocean spaces, we have to use ‘endpoint’ under the providerOptions, when the cdn URL is used as the endpoint strapi returns error code 500 for all media related actions.