The following two commands are separated by a pipe
| character, which means they will be executed together, in one go:
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
I need to run them separately, as two commands.
Actually these commands download and install the public signing key for elastic search.
But for some reason, they are giving me
gpg: no valid OpenPGP data found.
My web search tells me that executing both the commands separately might solve my problem. So I am trying to do that.
So the first command
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch returns fine, while the second one
sudo apt-key add - goes forever, and never returns.