diff options
author | Yifei Xue <xueyifei@huawei.com> | 2016-11-02 18:09:35 +0800 |
---|---|---|
committer | Yifei Xue <xueyifei@huawei.com> | 2016-11-17 15:24:46 +0800 |
commit | 35086233fdfb4163c589fc258229a931bb02df1a (patch) | |
tree | 7732c2e11fc4964ccaa65c74242386c4743a7edb /repo/jhenv_template | |
parent | b15421ac53b8f57011613e29505cd8c0275b5066 (diff) |
Create make_repo directory and optimize the current repo making related script
JIRA: COMPASS-496
Change-Id: I662d996382d38a3e9d0de6598dabe403b9d51665
Signed-off-by: Yifei Xue <xueyifei@huawei.com>
Diffstat (limited to 'repo/jhenv_template')
-rw-r--r-- | repo/jhenv_template/centos/rhel7/Dockerfile | 54 | ||||
-rw-r--r-- | repo/jhenv_template/ubuntu/trusty/Dockerfile | 54 | ||||
-rw-r--r-- | repo/jhenv_template/ubuntu/xenial/Dockerfile | 54 |
3 files changed, 162 insertions, 0 deletions
diff --git a/repo/jhenv_template/centos/rhel7/Dockerfile b/repo/jhenv_template/centos/rhel7/Dockerfile new file mode 100644 index 00000000..a47360aa --- /dev/null +++ b/repo/jhenv_template/centos/rhel7/Dockerfile @@ -0,0 +1,54 @@ +FROM centos:7.1.1503 +MAINTAINER Yifei Xue <xueyifei@huawei.com> + +ADD ./cp_env.sh /cp_env.sh + +#RUN yum provides '*/applydeltarpm' -y + +#RUN yum install deltarpm -y + +RUN yum remove -y systemd + +RUN yum update -y + +RUN yum install yum-plugin-downloadonly + +RUN mkdir -p /rpm + +RUN yum install -y epel-release-7-8 + +RUN yum groupinstall -y --downloadonly --downloaddir=/rpm 'Development Tools' + +RUN yum install -y --downloadonly --downloaddir=/rpm epel-release mkisofs bc curl ipmitool \ +git python-pip python-devel figlet \ +libxslt-devel libxml2-devel libvirt-devel \ +qemu qemu-kvm qemu-img virt-manager libvirt libvirt-python libvirt-client virt-install virt-viewer \ +guestfish libguestfs-tools virt-top mysql-devel \ +openssl-devel libffi libffi-devel python-cffi + +RUN yum install -y epel-release mkisofs bc curl ipmitool \ +git python-pip python-devel figlet \ +libxslt-devel libxml2-devel libvirt-devel \ +qemu qemu-kvm qemu-img virt-manager libvirt libvirt-python libvirt-client virt-install virt-viewer \ +guestfish libguestfs-tools virt-top mysql-devel \ +openssl-devel libffi libffi-devel python-cffi + +RUN yum install -y python-pip + +RUN yum install -y tar + +RUN tar -zcvf env_rel7_rpm.tar.gz /rpm + +RUN mkdir -p /home/pip + +RUN pip install --upgrade markupsafe virtualenv netaddr pbr oslo.config Cheetah ansible -d /home/pip/ + +RUN tar -zcvf env_rel7_pip.tar.gz /home/pip + +RUN mkdir -p /home/tmp + +RUN cp *.tar.gz /home/tmp + +RUN chmod +x /cp_env.sh + +CMD ["/cp_env.sh"] diff --git a/repo/jhenv_template/ubuntu/trusty/Dockerfile b/repo/jhenv_template/ubuntu/trusty/Dockerfile new file mode 100644 index 00000000..4eeccb6c --- /dev/null +++ b/repo/jhenv_template/ubuntu/trusty/Dockerfile @@ -0,0 +1,54 @@ +FROM ubuntu:14.04.3 +MAINTAINER Yifei Xue <xueyifei@huawei.com> + +ADD ./cp_env.sh /cp_env.sh + +RUN apt-get update + +RUN apt-get install -y wget + +RUN apt-get install -y -d mkisofs bc curl ipmitool openvswitch-switch \ +git python-pip python-dev figlet \ +libxslt-dev libxml2-dev libvirt-dev \ +build-essential qemu-utils qemu-kvm libvirt-bin \ +virtinst libmysqld-dev \ +libssl-dev libffi-dev python-cffi + +RUN wget -P /var/cache/apt/archives/ http://launchpadlibrarian.net/225838998/libffi6_3.1~rc1+r3.0.13-12ubuntu0.1_amd64.deb + +RUN mkdir jh_deb + +RUN cp /var/cache/apt/archives/*.deb jh_deb/ + +RUN apt-get install -y reprepro + +RUN mkdir -p trusty-jh-ppa/conf + +RUN echo 'Codename: trusty\n\ +Components: main\n\ +Architectures: amd64\n'\ +>> trusty-jh-ppa/conf/distributions + +RUN reprepro -b trusty-jh-ppa includedeb trusty jh_deb/*.deb + +RUN tar -zcvf /jh-ppa-trusty.tar.gz ./trusty-jh-ppa + +RUN apt-get install -y python-pip + +RUN mkdir jh_pip + +RUN pip install --upgrade paramiko jinja2 PyYAML setuptools pycrypto pyasn1 \ +cryptography MarkupSafe idna six enum34 ipaddress cffi pycparser \ +virtualenv cheetah requests netaddr pbr oslo.config ansible -d jh_pip/ + +RUN tar -zcvf jh_pip.tar.gz jh_pip/ + +RUN mkdir jh_env_package + +RUN mv *.tar.gz jh_env_package/ + +RUN tar -zcvf jh_env_trusty.tar.gz jh_env_package/ + +RUN chmod +x /cp_env.sh + +CMD ["/cp_env.sh"] diff --git a/repo/jhenv_template/ubuntu/xenial/Dockerfile b/repo/jhenv_template/ubuntu/xenial/Dockerfile new file mode 100644 index 00000000..6b9b517a --- /dev/null +++ b/repo/jhenv_template/ubuntu/xenial/Dockerfile @@ -0,0 +1,54 @@ +FROM ubuntu:16.04 +MAINTAINER Yifei Xue <xueyifei@huawei.com> + +ADD ./cp_env.sh /cp_env.sh + +RUN apt-get update + +RUN apt-get install -y wget + +RUN apt-get install -y -d mkisofs bc curl ipmitool openvswitch-switch \ +git python-pip python-dev figlet \ +libxslt-dev libxml2-dev libvirt-dev \ +build-essential qemu-utils qemu-kvm libvirt-bin \ +virtinst libmysqld-dev \ +libssl-dev libffi-dev python-cffi + +#RUN wget -P /var/cache/apt/archives/ http://launchpadlibrarian.net/225838998/libffi6_3.1~rc1+r3.0.13-12ubuntu0.1_amd64.deb + +RUN mkdir jh_deb + +RUN cp /var/cache/apt/archives/*.deb jh_deb/ + +RUN apt-get install -y reprepro + +RUN mkdir -p xenial-jh-ppa/conf + +RUN echo 'Codename: xenial\n\ +Components: main\n\ +Architectures: amd64\n'\ +>> xenial-jh-ppa/conf/distributions + +RUN reprepro -b xenial-jh-ppa includedeb xenial jh_deb/*.deb + +RUN tar -zcvf /jh-ppa-xenial.tar.gz ./xenial-jh-ppa + +RUN apt-get install -y python-pip + +RUN mkdir jh_pip + +RUN pip install --upgrade paramiko jinja2 PyYAML setuptools pycrypto pyasn1 \ +cryptography MarkupSafe idna six enum34 ipaddress cffi pycparser \ +virtualenv cheetah requests netaddr pbr oslo.config ansible -d jh_pip/ + +RUN tar -zcvf jh_pip.tar.gz jh_pip/ + +RUN mkdir jh_env_package + +RUN mv *.tar.gz jh_env_package/ + +RUN tar -zcvf jh_env_xenial.tar.gz jh_env_package/ + +RUN chmod +x /cp_env.sh + +CMD ["/cp_env.sh"] |