Welcome to Grafana Labs's package repository

Debian

If your distribution supports the signed-by option:
    
$ mkdir -p /etc/apt/keyrings/
$ wget -q -O - https://apt.grafana.com/gpg.key | gpg --dearmor > /etc/apt/keyrings/grafana.gpg
$ echo "deb [signed-by=/etc/apt/keyrings/grafana.gpg] https://apt.grafana.com stable main" | tee /etc/apt/sources.list.d/grafana.list
    
Otherwise, with the deprecated apt-key command:
    
$ echo "deb https://apt.grafana.com stable main" | tee /etc/apt/sources.list.d/grafana.list
$ wget -q -O - https://apt.grafana.com/gpg.key | apt-key add -
    

yum/dnf

    
$ nano /etc/yum.repos.d/grafana.repo
[grafana]
name=grafana
baseurl=https://rpm.grafana.com
repo_gpgcheck=1
enabled=1
gpgcheck=1
gpgkey=https://rpm.grafana.com/gpg.key
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt