]> git.proxmox.com Git - ceph.git/blame - ceph/src/arrow/dev/tasks/linux-packages/travis.linux.arm64.yml
import quincy 17.2.0
[ceph.git] / ceph / src / arrow / dev / tasks / linux-packages / travis.linux.arm64.yml
CommitLineData
1d09f67e
TL
1# Licensed to the Apache Software Foundation (ASF) under one
2# or more contributor license agreements. See the NOTICE file
3# distributed with this work for additional information
4# regarding copyright ownership. The ASF licenses this file
5# to you under the Apache License, Version 2.0 (the
6# "License"); you may not use this file except in compliance
7# with the License. You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing,
12# software distributed under the License is distributed on an
13# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14# KIND, either express or implied. See the License for the
15# specific language governing permissions and limitations
16# under the License.
17
18{% import 'macros.jinja' as macros with context %}
19
20arch: arm64-graviton2
21virt: vm
22os: linux
23dist: focal
24group: edge
25language: minimal
26
27addons:
28 apt:
29 packages:
30 - apt-utils
31 # We need Ubuntu 20.10 or later
32 # - createrepo_c
33 - devscripts
34 - gpg
35 - libgit2-dev
36 - python3-pip
37 - rake
38 - rpm
39
40 # https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1916485
41 # We need to use runc 1.0.0~rc93 or later from focal-updated.
42 - runc
43
44 # To build createrepo_c from source.
45 # We can remove them when we can install createrepo_c package
46 - cmake
47 - libbz2-dev
48 - libcurl4-openssl-dev
49 - libglib2.0-dev
50 - liblzma-dev
51 - libmagic-dev
52 - librpm-dev
53 - libsqlite3-dev
54 - libssl-dev
55 - libxml2-dev
56 - libzstd-dev
57 - pkg-config
58 - zlib1g-dev
59 update: true
60
61services:
62 - docker
63
64# don't build twice
65if: tag IS blank
66
67env:
68 global:
69 - APT_TARGETS={{ target }}
70 - ARROW_VERSION={{ arrow.version }}
71 - BUILD_REF={{ arrow.head }}
72 - TRAVIS_TAG={{ task.tag }}
73 - YUM_TARGETS={{ target }}
74
75before_script:
76 - set -e
77 {{ macros.travis_checkout_arrow() }}
78 {{ macros.travis_docker_login() }}
79
80 # Build createrepo_c from source.
81 # We can remove them when we can install createrepo_c package
82 - git clone --depth 1 https://github.com/rpm-software-management/createrepo_c.git
83 - pushd createrepo_c
84 - |
85 /usr/bin/cmake \
86 -DCMAKE_INSTALL_PREFIX=/usr \
87 -DENABLE_BASHCOMP=OFF \
88 -DENABLE_DRPM=OFF \
89 -DENABLE_PYTHON=OFF \
90 -DWITH_LIBMODULEMD=OFF \
91 -DWITH_ZCHUNK=OFF \
92 .
93 - make -j$(nproc)
94 - sudo make install
95 - popd
96 - rm -rf createrepo_c
97
98script:
99 # Build packages
100 - pushd arrow/dev/tasks/linux-packages
101 - rake version:update
102 - |
103 rake docker:pull || :
104 - pushd apache-arrow-apt-source/apt
105 - |
106 for target in debian-* ubuntu-*; do
107 cp -a ${target} ${target}-arm64
108 done
109 - popd
110 - pushd apache-arrow-release/yum
111 - |
112 for target in almalinux-* centos-*; do
113 cp -a ${target} ${target}-aarch64
114 done
115 - popd
116 - |
117 rake \
118 --trace \
119 {{ task_namespace }}:build \
120 BUILD_DIR=build \
121 DEB_BUILD_OPTIONS=parallel=2 \
122 RPM_BUILD_NCPUS=2
123 - sudo rm -rf */*/build
124 - popd
125 # Push Docker image
126 - pushd arrow/dev/tasks/linux-packages
127 - |
128 docker login -u "${DOCKERHUB_USER}" \
129 -p "${DOCKERHUB_TOKEN}" || :
130 - |
131 rake docker:push || :
132 - popd
133 # Test built packages
134 - sudo gem install apt-dists-merge
135 - |
136 (echo "Key-Type: RSA"; \
137 echo "Key-Length: 4096"; \
138 echo "Name-Real: Test"; \
139 echo "Name-Email: test@example.com"; \
140 echo "%no-protection") | \
141 gpg --full-generate-key --batch
142 - |
143 GPG_KEY_ID=$(gpg --list-keys --with-colon test@example.com | grep fpr | cut -d: -f10)
144 - gpg --export --armor test@example.com > arrow/dev/tasks/linux-packages/KEYS
145 - pushd arrow/dev/tasks/linux-packages
146 - |
147 rake --trace {{ task_namespace }}:test \
148 CREATEREPO=createrepo_c \
149 GPG_KEY_ID=${GPG_KEY_ID}
150 - rm -rf {{ task_namespace }}/repositories
151 - popd
152
153after_success:
154 {% set patterns = upload_extensions | format_all("arrow/dev/tasks/linux-packages/**/*{}") %}
155 {{ macros.travis_upload_releases(patterns) }}