Hi Sarun,
This looks like an issue with Rubygems that I’ve seen on the Ubuntu containers. It’s a bug with recent versions of Rubygems and certain combinations of Rubygems and Bundler. I’ll bring this to the attention of our OS X team. As a workaround, can you try seeing if this fixes the error?
sudo gem update --system 2.4.8
gem uninstall bundler
gem install bundler