summaryrefslogtreecommitdiffstats
path: root/repo/openstack/make_ppa/centos/rhel7
diff options
context:
space:
mode:
authorJustin chi <chigang@huawei.com>2016-11-24 08:47:48 +0000
committerGerrit Code Review <gerrit@opnfv.org>2016-11-24 08:47:48 +0000
commit36f5cffcf373a8a12677c8e406cd11c8d9ffe2bb (patch)
treea20455421b7bdf19890032ce4da74ceee3a46762 /repo/openstack/make_ppa/centos/rhel7
parent2446530c3230221d76877851012eb39e2a7c0360 (diff)
parent35086233fdfb4163c589fc258229a931bb02df1a (diff)
Merge "Create make_repo directory and optimize the current repo making related script"
Diffstat (limited to 'repo/openstack/make_ppa/centos/rhel7')
-rw-r--r--repo/openstack/make_ppa/centos/rhel7/compass/download_pkg.tmpl42
-rw-r--r--repo/openstack/make_ppa/centos/rhel7/juno/download_pkg.tmpl95
-rw-r--r--repo/openstack/make_ppa/centos/rhel7/kilo/download_pkg.tmpl103
-rw-r--r--repo/openstack/make_ppa/centos/rhel7/liberty/download_pkg.tmpl98
-rw-r--r--repo/openstack/make_ppa/centos/rhel7/mitaka/download_pkg.tmpl79
5 files changed, 417 insertions, 0 deletions
diff --git a/repo/openstack/make_ppa/centos/rhel7/compass/download_pkg.tmpl b/repo/openstack/make_ppa/centos/rhel7/compass/download_pkg.tmpl
new file mode 100644
index 00000000..1cb34b49
--- /dev/null
+++ b/repo/openstack/make_ppa/centos/rhel7/compass/download_pkg.tmpl
@@ -0,0 +1,42 @@
+#!/bin/bash
+set -x
+
+# add openstack kilo repo
+yum install http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm -y
+yum install http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-5.noarch.rpm -y
+
+cat << EOF >/etc/yum.repos.d/elasticsearch.repo
+[elasticsearch-2.x]
+name=Elasticsearch repository for 2.x packages
+baseurl=http://packages.elastic.co/elasticsearch/2.x/centos
+gpgcheck=1
+gpgkey=http://packages.elastic.co/GPG-KEY-elasticsearch
+enabled=1
+EOF
+
+cat << EOF >/etc/yum.repos.d/logstash.repo
+[logstash-2.0]
+name=Logstash repository for 2.0.x packages
+baseurl=http://packages.elastic.co/logstash/2.0/centos
+gpgcheck=1
+gpgkey=http://packages.elastic.co/GPG-KEY-elasticsearch
+enabled=1
+EOF
+
+yum update -y
+
+mkdir -p /centos7-compass-core
+yum -y reinstall bind-license --downloadonly --downloaddir=/centos7-compass-core
+yum -y reinstall openssl-libs --downloadonly --downloaddir=/centos7-compass-core
+
+#download packages
+#set packages = $getVar('default_packages', [])
+yum -y install --skip-broken --downloadonly --downloaddir=/centos7-compass-core #echo ' '.join(packages)
+#set packages = $getVar('packages', [])
+yum -y install --skip-broken --downloadonly --downloaddir=/centos7-compass-core #echo ' '.join(packages)
+#make repo
+
+find /var/cache/yum/ -name "*.rpm" | xargs -i cp {} /centos7-compass-core
+
+yum install tar -y
+tar -zcvf /centos7-compass-core.tar.gz /centos7-compass-core
diff --git a/repo/openstack/make_ppa/centos/rhel7/juno/download_pkg.tmpl b/repo/openstack/make_ppa/centos/rhel7/juno/download_pkg.tmpl
new file mode 100644
index 00000000..7a87d2d1
--- /dev/null
+++ b/repo/openstack/make_ppa/centos/rhel7/juno/download_pkg.tmpl
@@ -0,0 +1,95 @@
+#!/bin/bash
+set -x
+
+#set OPV="juno"
+
+yum remove systemd -y
+# add 163 repo
+yum install wget -y
+wget -O /epel-release-7-5.noarch.rpm http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-5.noarch.rpm
+yum remove wget iptables-services -y
+yum update -y
+#rm -f /etc/yum.repos.d/CentOS-*.repo
+yum repolist
+yum clean all
+
+yum install yum-plugin-priorities -y
+yum install http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-5.noarch.rpm -y
+yum install http://rdo.fedorapeople.org/openstack-$OPV/rdo-release-${OPV}.rpm -y
+
+# modify centos7 repo for workaround
+sed -i 's/epel-Derived from Red Hat Enterprise Linux 7.1 (Source)/epel-7/g' /etc/yum.repos.d/rdo-release.repo
+
+
+# add galeracluster repo
+cat <<EOF >/etc/yum.repos.d/MariaDB.repo
+[mariadb]
+name =MariaDB
+baseurl = http://yum.mariadb.org/5.5/centos7-amd64
+gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
+gpgcheck=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/syslog.repo
+[rsyslog_v7]
+name=rsyslog
+baseurl="http://rpms.adiscon.com/v7-stable/epel-7/x86_64"
+enabled=1
+gpgcheck=0
+gpgkey=http://rpms.adiscon.com/RPM-GPG-KEY-Adiscon
+protect=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/ceph.repo
+[ceph]
+name=Ceph packages for x86_64
+baseurl=http://ceph.com/rpm-hammer/rhel7/x86_64
+enabled=1
+priority=2
+gpgcheck=1
+type=rpm-md
+gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
+
+[ceph-noarch]
+name=Ceph noarch packages
+baseurl=http://ceph.com/rpm-hammer/rhel7/noarch
+enabled=1
+priority=2
+gpgcheck=1
+type=rpm-md
+gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
+EOF
+
+cat <<EOF >>/etc/yum.conf
+exclude=mongodb-org,mongodb-org-server
+EOF
+
+yum update -y
+yum install createrepo tar -y
+
+yum -y install --downloadonly MariaDB-Galera-server
+#download packages
+#set packages = $getVar('default_packages', [])
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+#set packages = $getVar('packages', [])
+#silent packages.pop(packages.index('MariaDB-Galera-server'))
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+
+#make repo
+
+mkdir -p /centos7-$OPV-ppa/{Packages,repodata}
+
+find /var/cache/yum/ -name "*.rpm" | xargs -i cp {} /centos7-$OPV-ppa/Packages/
+
+rm /centos7-$OPV-ppa/Packages/selinux-policy* -f
+rm /centos7-$OPV-ppa/Packages/systemd* -f
+
+mv /epel-release-7-5.noarch.rpm /centos7-$OPV-ppa/Packages/
+cp /comps.xml /centos7-$OPV-ppa/
+cp /ceph_key_release.asc /centos7-$OPV-ppa/
+createrepo -g comps.xml /centos7-$OPV-ppa
+mkdir /centos7-$OPV-ppa/noarch
+mkdir /centos7-$OPV-ppa/noarch/Packages
+cp -r /centos7-$OPV-ppa/Packages/ceph* /centos7-$OPV-ppa/noarch/Packages/
+cp -r /centos7-$OPV-ppa/repodata/ /centos7-$OPV-ppa/noarch/
+tar -zcvf /centos7-$OPV-ppa.tar.gz /centos7-$OPV-ppa
diff --git a/repo/openstack/make_ppa/centos/rhel7/kilo/download_pkg.tmpl b/repo/openstack/make_ppa/centos/rhel7/kilo/download_pkg.tmpl
new file mode 100644
index 00000000..9aad1b33
--- /dev/null
+++ b/repo/openstack/make_ppa/centos/rhel7/kilo/download_pkg.tmpl
@@ -0,0 +1,103 @@
+#!/bin/bash
+set -x
+
+#set OPV="kilo"
+
+yum remove systemd -y
+# add 163 repo
+yum install wget -y
+wget -O /epel-release-7-5.noarch.rpm http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-5.noarch.rpm
+yum remove wget iptables-services -y
+yum update -y
+#rm -f /etc/yum.repos.d/CentOS-*.repo
+yum repolist
+yum clean all
+
+yum install yum-plugin-priorities -y
+yum install http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-5.noarch.rpm -y
+yum install http://rdo.fedorapeople.org/openstack-$OPV/rdo-release-${OPV}.rpm -y
+
+# modify centos7 repo for workaround
+sed -i 's/epel-Derived from Red Hat Enterprise Linux 7.1 (Source)/epel-7/g' /etc/yum.repos.d/rdo-release.repo
+
+# add galeracluster repo
+cat <<EOF >/etc/yum.repos.d/MariaDB.repo
+[mariadb]
+name =MariaDB
+baseurl = http://yum.mariadb.org/5.5/centos7-amd64
+gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
+gpgcheck=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/syslog.repo
+[rsyslog_v7]
+name=rsyslog
+baseurl="http://rpms.adiscon.com/v7-stable/epel-7/x86_64"
+enabled=1
+gpgcheck=0
+gpgkey=http://rpms.adiscon.com/RPM-GPG-KEY-Adiscon
+protect=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/ceph.repo
+[ceph]
+name=Ceph packages for x86_64
+baseurl=http://ceph.com/rpm-hammer/rhel7/x86_64
+enabled=1
+priority=2
+gpgcheck=1
+type=rpm-md
+gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
+
+[ceph-noarch]
+name=Ceph noarch packages
+baseurl=http://ceph.com/rpm-hammer/rhel7/noarch
+enabled=1
+priority=2
+gpgcheck=1
+type=rpm-md
+gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
+EOF
+
+cat <<EOF >/etc/yum.repos.d/mongo.repo
+[10gen]
+name=10gen Repository
+baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64
+gpgcheck=0
+EOF
+
+cat <<EOF >>/etc/yum.conf
+exclude=mongodb-org,mongodb-org-server
+EOF
+
+yum update -y
+yum install createrepo tar -y
+
+yum -y install --downloadonly MariaDB-Galera-server
+#download packages
+#set packages = $getVar('default_packages', [])
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+#set packages = $getVar('packages', [])
+#silent packages.pop(packages.index('MariaDB-Galera-server'))
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+
+#make repo
+
+mkdir -p /centos7-$OPV-ppa/{Packages,repodata}
+
+find /var/cache/yum/ -name "*.rpm" | xargs -i cp {} /centos7-$OPV-ppa/Packages/
+
+rm /centos7-$OPV-ppa/Packages/selinux-policy* -f
+rm /centos7-$OPV-ppa/Packages/systemd* -f
+rm /centos7-$OPV-ppa/Packages/openssl-1.0.1e-42.el7.9.x86_64.rpm
+rm /centos7-$OPV-ppa/Packages/libnl3-3.2.21-9.el7_1.x86_64.rpm
+
+mv /epel-release-7-5.noarch.rpm /centos7-$OPV-ppa/Packages/
+cp /comps.xml /centos7-$OPV-ppa/
+cp /ceph_key_release.asc /centos7-$OPV-ppa/
+createrepo -g comps.xml /centos7-$OPV-ppa
+mkdir /centos7-$OPV-ppa/noarch
+mkdir /centos7-$OPV-ppa/noarch/Packages
+cp -r /centos7-$OPV-ppa/Packages/ceph* /centos7-$OPV-ppa/noarch/Packages/
+cp -r /centos7-$OPV-ppa/repodata/ /centos7-$OPV-ppa/noarch/
+tar -zcvf /centos7-$OPV-ppa.tar.gz /centos7-$OPV-ppa
diff --git a/repo/openstack/make_ppa/centos/rhel7/liberty/download_pkg.tmpl b/repo/openstack/make_ppa/centos/rhel7/liberty/download_pkg.tmpl
new file mode 100644
index 00000000..24781785
--- /dev/null
+++ b/repo/openstack/make_ppa/centos/rhel7/liberty/download_pkg.tmpl
@@ -0,0 +1,98 @@
+#!/bin/bash
+set -x
+
+#set OPV="liberty"
+
+yum remove systemd -y
+# add 163 repo
+#rm -f /etc/yum.repos.d/CentOS-*.repo
+yum repolist
+yum clean all
+
+yum install yum-plugin-priorities -y
+yum install http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-6.noarch.rpm -y
+yum install http://rdo.fedorapeople.org/openstack-$OPV/rdo-release-${OPV}.rpm -y
+
+# modify centos7 repo for workaround
+sed -i 's/epel-Derived from Red Hat Enterprise Linux 7.1 (Source)/epel-7/g' /etc/yum.repos.d/rdo-release.repo
+
+# add mongodb repo
+cat <<EOF >/etc/yum.repos.d/mongodb.repo
+[mongodb]
+name=MongoDB Repository
+baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64/
+gpgcheck=0
+enabled=1
+EOF
+
+# add galeracluster repo
+cat <<EOF >/etc/yum.repos.d/MariaDB.repo
+[mariadb]
+name =MariaDB
+baseurl = http://yum.mariadb.org/5.5/centos7-amd64
+gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
+gpgcheck=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/syslog.repo
+[rsyslog_v7]
+name=rsyslog
+baseurl="http://rpms.adiscon.com/v7-stable/epel-7/x86_64"
+enabled=1
+gpgcheck=0
+gpgkey=http://rpms.adiscon.com/RPM-GPG-KEY-Adiscon
+protect=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/ceph.repo
+[ceph]
+name=Ceph packages for x86_64
+baseurl=http://ceph.com/rpm-hammer/rhel7/x86_64
+enabled=1
+priority=2
+gpgcheck=1
+type=rpm-md
+gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
+
+[ceph-noarch]
+name=Ceph noarch packages
+baseurl=http://ceph.com/rpm-hammer/rhel7/noarch
+enabled=1
+priority=2
+gpgcheck=1
+type=rpm-md
+gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
+EOF
+
+cat <<EOF >>/etc/yum.conf
+exclude=mongodb-org,mongodb-org-server
+EOF
+
+yum update -y
+yum install createrepo tar -y
+
+yum -y install --downloadonly MariaDB-Galera-server
+#download packages
+#set packages = $getVar('default_packages', [])
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+#set packages = $getVar('packages', [])
+#silent packages.pop(packages.index('MariaDB-Galera-server'))
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+
+#make repo
+mkdir -p /centos7-$OPV-ppa/{Packages,repodata}
+
+find /var/cache/yum/ -name "*.rpm" | xargs -i cp {} /centos7-$OPV-ppa/Packages/
+
+rm /centos7-$OPV-ppa/Packages/selinux-policy* -f
+rm /centos7-$OPV-ppa/Packages/systemd* -f
+
+mv /epel-release-7-5.noarch.rpm /centos7-$OPV-ppa/Packages/
+cp /comps.xml /centos7-$OPV-ppa/
+cp /ceph_key_release.asc /centos7-$OPV-ppa/
+createrepo -g comps.xml /centos7-$OPV-ppa
+mkdir /centos7-$OPV-ppa/noarch
+mkdir /centos7-$OPV-ppa/noarch/Packages
+cp -r /centos7-$OPV-ppa/Packages/ceph* /centos7-$OPV-ppa/noarch/Packages/
+cp -r /centos7-$OPV-ppa/repodata/ /centos7-$OPV-ppa/noarch/
+tar -zcvf /centos7-$OPV-ppa.tar.gz /centos7-$OPV-ppa
diff --git a/repo/openstack/make_ppa/centos/rhel7/mitaka/download_pkg.tmpl b/repo/openstack/make_ppa/centos/rhel7/mitaka/download_pkg.tmpl
new file mode 100644
index 00000000..4d6b26fd
--- /dev/null
+++ b/repo/openstack/make_ppa/centos/rhel7/mitaka/download_pkg.tmpl
@@ -0,0 +1,79 @@
+#!/bin/bash
+set -x
+
+#set OPV="mitaka"
+
+yum remove systemd -y
+# add 163 repo
+#rm -f /etc/yum.repos.d/CentOS-*.repo
+yum repolist
+yum clean all
+
+yum install yum-plugin-priorities -y
+# yum install http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-6.noarch.rpm -y
+# yum install http://rdo.fedorapeople.org/openstack-$OPV/rdo-release-${OPV}.rpm -y
+yum install -y centos-release-openstack-${OPV}
+
+# modify centos7 repo for workaround
+# sed -i 's/epel-Derived from Red Hat Enterprise Linux 7.1 (Source)/epel-7/g' /etc/yum.repos.d/rdo-release.repo
+
+# add mongodb repo
+cat <<EOF >/etc/yum.repos.d/mongodb.repo
+[mongodb]
+name=MongoDB Repository
+baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64/
+gpgcheck=0
+enabled=1
+EOF
+
+# add galeracluster repo
+cat <<EOF >/etc/yum.repos.d/MariaDB.repo
+[mariadb]
+name =MariaDB
+baseurl = http://yum.mariadb.org/5.5/centos7-amd64
+gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
+gpgcheck=1
+EOF
+
+cat <<EOF >/etc/yum.repos.d/syslog.repo
+[rsyslog_v7]
+name=rsyslog
+baseurl="http://rpms.adiscon.com/v7-stable/epel-7/x86_64"
+enabled=1
+gpgcheck=0
+gpgkey=http://rpms.adiscon.com/RPM-GPG-KEY-Adiscon
+protect=1
+EOF
+
+cat <<EOF >>/etc/yum.conf
+exclude=mongodb-org,mongodb-org-server
+EOF
+
+yum update -y
+yum install createrepo tar -y
+
+yum -y install --downloadonly MariaDB-Galera-server
+#download packages
+#set packages = $getVar('default_packages', [])
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+#set packages = $getVar('packages', [])
+#silent packages.pop(packages.index('MariaDB-Galera-server'))
+yum -y install --skip-broken --downloadonly #echo ' '.join(packages)
+
+#make repo
+mkdir -p /centos7-$OPV-ppa/{Packages,repodata}
+
+find /var/cache/yum/ -name "*.rpm" | xargs -i cp {} /centos7-$OPV-ppa/Packages/
+
+rm /centos7-$OPV-ppa/Packages/selinux-policy* -f
+rm /centos7-$OPV-ppa/Packages/systemd* -f
+
+mv /epel-release-7-5.noarch.rpm /centos7-$OPV-ppa/Packages/
+cp /comps.xml /centos7-$OPV-ppa/
+cp /ceph_key_release.asc /centos7-$OPV-ppa/
+createrepo -g comps.xml /centos7-$OPV-ppa
+mkdir /centos7-$OPV-ppa/noarch
+mkdir /centos7-$OPV-ppa/noarch/Packages
+cp -r /centos7-$OPV-ppa/Packages/ceph* /centos7-$OPV-ppa/noarch/Packages/
+cp -r /centos7-$OPV-ppa/repodata/ /centos7-$OPV-ppa/noarch/
+tar -zcvf /centos7-$OPV-ppa.tar.gz /centos7-$OPV-ppa