<p>Tring to install kubernetes cluster with kubeadm, and faced issue with installing kube packages.
I continue getting error:</p>
<pre><code>https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64/repodata/repomd.xml: [Errno -1] repomd.xml signature could not be verified for kubernetes
</code></pre>
<p>Repo config:</p>
<pre><code>    [kubernetes]
    name=Kubernetes
    baseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64
    enabled=1
    gpgcheck=1
    repo_gpgcheck=1
    gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
    exclude=kubelet kubeadm kubectl
</code></pre>
<p>Im using centos 7 distro</p>
<pre><code>Linux kube-master 3.10.0-1160.21.1.el7.x86_64 #1 SMP Tue Mar 16 18:28:22 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
</code></pre>

<p>You can see very similar issue <a href="https://github.com/kubernetes/kubernetes/issues/60134" rel="noreferrer">here</a>.</p>
<p>As a <strong>quick workaround</strong>, you can simply disable <strong>GPG checking</strong> by setting <code>repo_gpgcheck=0</code> in <code>/etc/yum.repos.d/kubernetes.repo</code> but this is obviously not recommended from security perspective.</p>
<p>Additionally you may try the following:</p>
<ul>
<li><p>re-import the keys as suggested <a href="https://github.com/kubernetes/kubernetes/issues/60134#issuecomment-385942005" rel="noreferrer">here</a></p>
<pre><code>rpm --import https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
</code></pre>
</li>
<li><p>install the following version of <strong>GNUPG</strong> as suggested <a href="https://github.com/kubernetes/kubernetes/issues/60134#issuecomment-573247871" rel="noreferrer">here</a></p>
<pre><code>sudo yum install -y http://mirror.centos.org/centos/7/os/x86_64/Packages/gnupg2-2.0.22-5.el7_5.x86_64.rpm
</code></pre>
</li>
</ul>
