[node-patches] Change in ovirt-node-iso[ovirt-3.5]: Update repo generation script

fabiand at redhat.com fabiand at redhat.com
Fri Nov 14 15:09:47 UTC 2014


Fabian Deutsch has uploaded a new change for review.

Change subject: Update repo generation script
......................................................................

Update repo generation script

Change-Id: Ia2d06362cf98638e791d7ccdec7a708760a0b184
Signed-off-by: Fabian Deutsch <fabiand at fedoraproject.org>
---
M generate-repos.sh
1 file changed, 20 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node-iso refs/changes/73/35173/1

diff --git a/generate-repos.sh b/generate-repos.sh
index 1363e65..c9a0ab1 100755
--- a/generate-repos.sh
+++ b/generate-repos.sh
@@ -1,14 +1,17 @@
 #!/usr/bin/bash
 
+# 35
 OVERSION=$1
+# el
 DIST=$2
+RELEASEVER=$(echo $DIST | egrep -o "[0-9]+")
 
 #
 # URLs to release files containing the repositories to use
 #
 OVIRT_RELEASE_FILE_URL=http://resources.ovirt.org/pub/yum-repo/ovirt-release$OVERSION.rpm
 FEDORA_RELEASE_FILE_URL=http://download.fedoraproject.org/pub/fedora/linux/releases/20/Fedora/x86_64/os/Packages/f/fedora-release-20-1.noarch.rpm
-CENTOS_RELEASE_FILE_URL=http://mirror.centos.org/centos/6/os/x86_64/Packages/centos-release-6-5.el6.centos.11.1.x86_64.rpm
+CENTOS_RELEASE_FILE_URL=http://mirror.centos.org/centos/6/os/x86_64/Packages/centos-release-6-6.el6.centos.12.2.x86_64.rpm
 
 
 #
@@ -21,7 +24,7 @@
 }
 cpiocat() { cpio --quiet --to-stdout -i $@ ; }
 rpmcat() { RPM=$1 ; shift 1 ; rpm2cpio $RPM | cpiocat $@ ; }
-assert_url_exists() { curl -v -s $1 2>&1 | grep -q "HTTP/1.1 200" || die "URL does not exist: $1" ; }
+assert_url_exists() { curl -4 -v -s $1 2>&1 | grep -q "HTTP/1.1 200" || die "URL does not exist: $1" ; }
 die() { echo $@ >&2 ; exit 42 ; }
 
 [[ -z $OVERSION ]] && die "Missing ovirt version (i.e 34)"
@@ -45,7 +48,7 @@
 assert_url_exists $OVIRT_RELEASE_FILE_URL
 rpmcat $OVIRT_RELEASE_FILE_URL \
 	./usr/share/ovirt-release$OVERSION/ovirt.repo \
-	./usr/share/ovirt-release$OVERSION/ovirt-$DEPS-deps.repo \
+	./usr/share/ovirt-release$OVERSION/ovirt-$DIST-deps.repo \
 	| sed "s/@DIST@/$DEPS/" | hack_epel
 
 }
@@ -88,6 +91,16 @@
     ./etc/yum.repos.d/fedora-updates.repo
 }
 
+local_repo() {
+cat <<EOR
+
+[local]
+baseurl=http://127.0.0.1:8000/
+skip_if_unavailable=1
+
+EOR
+}
+
 # Output all repos:
 {
 #
@@ -95,10 +108,14 @@
 # $0 $@
 #
 
+# Local if available
+local_repo
+
 # oVirt
 ovirt_repo
 
 # Platform
 platform_repos
+
 }
 


-- 
To view, visit http://gerrit.ovirt.org/35173
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia2d06362cf98638e791d7ccdec7a708760a0b184
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node-iso
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Fabian Deutsch <fabiand at redhat.com>



More information about the node-patches mailing list