docs: fixed installation instruction for rhel/centos (#2143)

This commit is contained in:
DmitriyLewen
2022-05-18 00:19:33 +06:00
committed by GitHub
parent afe3292843
commit f8951f3847

View File

@@ -7,10 +7,11 @@
Add repository setting to `/etc/yum.repos.d`.
``` bash
RELEASE_VERSION=$(grep -Po '(?<=VERSION_ID=")[0-9]' /etc/os-release)
cat << EOF | sudo tee -a /etc/yum.repos.d/trivy.repo
[trivy]
name=Trivy repository
baseurl=https://aquasecurity.github.io/trivy-repo/rpm/releases/$releasever/$basearch/
baseurl=https://aquasecurity.github.io/trivy-repo/rpm/releases/$RELEASE_VERSION/\$basearch/
gpgcheck=0
enabled=1
EOF