AArch64 support 82/1682/4
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Mon, 30 Sep 2019 20:11:09 +0000 (22:11 +0200)
committerAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Thu, 17 Oct 2019 14:32:37 +0000 (16:32 +0200)
- spec: change hardcoded x86_64 arch to current platform arch;
- Dockerfile: Instead of pulling CentOS base images from dockerhub,
  create them from scratch from the official SIG-cloudinstance repo:
  http://artifacts.ci.centos.org/sig-cloudinstance/
- nginx.repo: Use $basearch instead of hardcoded x86_64;
- spec: Bump minor RPM version;

Co-authored-by: Jimmy Lafontaine Rivera <lafonj@gmail.com>
Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
Change-Id: I1415675c7b2aae250b8f5dbd1e370a84ee5a878f

SPECS/registry.spec
SPECS/swift.spec
docker-build/swift/Dockerfile
docker-build/swift/nginx.repo

index 15d883d..56a414c 100644 (file)
@@ -15,7 +15,7 @@
 %define COMPONENT registry
 %define RPM_NAME caas-%{COMPONENT}
 %define RPM_MAJOR_VERSION 2.7.1
-%define RPM_MINOR_VERSION 9
+%define RPM_MINOR_VERSION 10
 %define IMAGE_TAG %{RPM_MAJOR_VERSION}-%{RPM_MINOR_VERSION}
 %define go_version 1.12.10
 
@@ -25,7 +25,7 @@ Release:        %{RPM_MINOR_VERSION}%{?dist}
 Summary:        Containers as a Service Registry component
 License:        %{_platform_license} and Apache License and GNU Lesser General Public License v3.0 only and BSD 3-clause New or Revised License and MIT License and Common Development and Distribution License and BSD and GNU General Public License v2.0 only
 URL:            https://github.com/docker/distribution
-BuildArch:      x86_64
+BuildArch:      %{_arch}
 Vendor:         %{_platform_vendor} and docker/distribution unmodified
 Source0:        %{name}-%{version}.tar.gz
 
index 0564c6d..f1d2112 100644 (file)
 %define COMPONENT swift
 %define RPM_NAME caas-%{COMPONENT}
 %define RPM_MAJOR_VERSION 2.22.0
-%define RPM_MINOR_VERSION 2
+%define RPM_MINOR_VERSION 3
 %define IMAGE_TAG %{RPM_MAJOR_VERSION}-%{RPM_MINOR_VERSION}
+%define centos_build 191001
 Name:           %{RPM_NAME}
 Version:        %{RPM_MAJOR_VERSION}
 Release:        %{RPM_MINOR_VERSION}%{?dist}
 Summary:        Containers as a Service Swift component
 License:        %{_platform_license} and Apache License and GNU Lesser General Public License v3.0 only and BSD 3-clause New or Revised License and MIT License and Common Development and Distribution License and BSD and GNU General Public License v2.0 only
 URL:            https://github.com/openstack/swift
-BuildArch:      x86_64
+BuildArch:      %{_arch}
 Vendor:         %{_platform_vendor} and openstack/swift unmodified
 Source0:        %{name}-%{version}.tar.gz
 
 Requires: docker-ce >= 18.09.2, rsync
-BuildRequires: docker-ce-cli >= 18.09.2, xz
+BuildRequires: docker-ce-cli >= 18.09.2, xz, wget
 
 %description
 This rpm contains the swift container and ansible for caas subsystem.
@@ -38,6 +39,7 @@ This container contains the swift service.
 %autosetup
 
 %build
+wget --progress=dot:giga http://artifacts.ci.centos.org/sig-cloudinstance/centos-7-%{centos_build}/%{_arch}/centos-7-%{_arch}-docker.tar.xz -O %{_builddir}/%{RPM_NAME}-%{RPM_MAJOR_VERSION}/docker-build/%{COMPONENT}/centos-7-docker.tar.xz
 # Building the container
 docker build \
   --network=host \
index 2ff94a9..25fa9ad 100644 (file)
@@ -12,7 +12,9 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM centos:7.6.1810
+FROM scratch
+ADD centos-7-docker.tar.xz /
+CMD ["/bin/bash"]
 MAINTAINER Balint Varga <balint.varga@nokia.com>
 
 ARG SWIFT
index 67e94f6..af3f754 100644 (file)
@@ -1,6 +1,6 @@
 [nginx-epel-7]
 name=Nginx Epel
-baseurl=https://dl.fedoraproject.org/pub/epel/7/x86_64/
+baseurl=https://dl.fedoraproject.org/pub/epel/7/$basearch/
 enabled=1
 metadata_expire=1d
 gpgcheck=0