summaryrefslogtreecommitdiffstats
path: root/distribution/addrepo/runtest.sh
blob: 8bb53b65a4f0b934ed637f3d3a60a6ed19f01c4f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

if [ -z "$REPOURL" ]; then
echo "You need to specify \$REPOURL"
exit 1
fi

REPONAME=${REPONAME:="postrepo0"}
cat << EOF >/etc/yum.repos.d/${REPONAME}.repo
[${REPONAME}]
name=${REPONAME}
baseurl=$(eval echo ${REPOURL})
enabled=1
gpgcheck=0
skip_if_unavailable=1
EOF

exit 0