Hello @DanielArgelles-5927 and thank you for your question.
If I understand you correctly, you are currently using the provided code to set the ACL's but is taking too long.
Given that the bottleneck is on your process sending only one http request at a time, and the azure side can handle multiple requests simultaneously, one solution would be multi-threading on your end so you can send multiple requests in parallel.
Refactor, so you have one process gathering the list of files, (currently handled by your do-loop). Multiple other processes then consume filepaths from the list and return status codes.