bundler can't install rake because it can't verify ssl on the remote server (possibly because you're getting MITM'ed, you've got an ancient cacerts bundle, or something else is going on).
you can:
disable ssl verification via .gemrc (add ':ssl_verify_mode: 0' to your .gemrc)
disable ssl by removing the https source and adding the http-only source (gem source -r https://rubygems.org; gem source -a http://rubygems.org)
trust the MITM proxy ca cert by adding it in your ruby home's lib/ruby/<maj version>/rubygems/ssl_certs directory
I tend to sidestep all of these by running my own trusted internal rubygems mirror.
You might be interested in Crystal, which has the same syntax and stdlib as Ruby but compiled. I've been porting over some of my Ruby libraries so I can easily switch between both languages and have the same tools. Ruby is great for quick-and-dirty scripting, but if you need native performance, a strong Type System, ability to ship a single binary, there's Crystal. If you already know Ruby, learning Crystal is super easy.