I\'m trying to install Ruby on Ubuntu 16.04. However when I enter to following command to terminal:
$ \\curl -sSL https://get.rvm.io | bash -s stable --ruby
I am just posting an update solution for it as I faced the same issue in Ubuntu 18.04 while trying to fetch keys for RVM.
The following method is provided by RVM.
gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
If it doesn't work out and you try to install rvm directly, the process will fail and provides three suggestions to receive keys. One of which have a step to receive the keys with gpg2.
Install gpg2 in your system before that.
sudo apt install gnupg2
The command is
gpg2 --recv-keys 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
But this command too will not work. So here's an alternative. Just replace the gpg from the older command to gpg2 which worked for me.
gpg2 --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB