Added setup scripts for apt and yum repos

This commit is contained in:
Neil O'Toole 2022-11-19 18:58:11 -07:00
parent 67b2341e80
commit bc8cc1180d
2 changed files with 28 additions and 0 deletions

16
add-repo-apt.sh Executable file
View File

@ -0,0 +1,16 @@
#!/usr/bin/env sh
# This script adds the "sq" repo to apt.
apt update -y && apt install -y curl gpg
curl -fsSL https://apt.fury.io/neilotoole/gpg.key | gpg --dearmor -o /usr/share/keyrings/sq.gpg
echo "deb [signed-by=/usr/share/keyrings/sq.gpg] https://apt.fury.io/neilotoole/ * *" > /etc/apt/sources.list.d/sq.list
cat <<EOF > /etc/apt/preferences.d/sq
Package: sq
Pin: origin apt.fury.io
Pin-Priority: 501
EOF
apt update

12
add-repo-yum.sh Executable file
View File

@ -0,0 +1,12 @@
#!/usr/bin/env sh
# This script adds the "sq" repo to yum.
cat <<EOF > /etc/yum.repos.d/sq.repo
[sq]
name=sq
baseurl=https://yum.fury.io/neilotoole/
enabled=1
gpgcheck=0
gpgkey=https://apt.fury.io/neilotoole/gpg.key
EOF