To write the code from scratch, sure.
But I'm thinking a few lines of nginx config to proxy http 1.1 to 2