Add gen-yum to generate YUM/DNF repos
This commit is contained in:
parent
cd582bc29c
commit
10034a2b34
1 changed files with 22 additions and 0 deletions
22
gen-yum
Executable file
22
gen-yum
Executable file
|
@ -0,0 +1,22 @@
|
|||
#!/bin/bash
|
||||
# Setup YUM/DNF repository
|
||||
|
||||
GPG_KEY=F77BB18D
|
||||
eval BASE_DIRS=~/www_static/dnf.bl0rg.net/*/*
|
||||
|
||||
set -e
|
||||
|
||||
for base_dir in $BASE_DIRS; do
|
||||
for YUM in $base_dir/{i386,x86_64}; do
|
||||
if [ -d $YUM ]; then
|
||||
echo "== $YUM"
|
||||
cd $YUM
|
||||
createrepo --update --checkts .
|
||||
if [ ! -e repodata/repomd.xml.asc \
|
||||
-o repodata/repomd.xml.asc -ot repodata/repomd.xml ]; then
|
||||
rm -f repodata/repomd.xml.asc
|
||||
gpg -u $GPG_KEY --detach-sign --armor repodata/repomd.xml
|
||||
fi
|
||||
fi
|
||||
done
|
||||
done
|
Loading…
Add table
Add a link
Reference in a new issue