Properly handle io.copy errors

Summary

We already tried to do that in 4f047b8f, but we didn't handle Context.Cancelled errors, so it cause a production incident gitlab-com/gl-infra/production#6256 (closed)

Steps to reproduce

Possible fixes

~"devops::release" ~"group::release" Category:Pages

Edited by Vladimir Shushlin