-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile.cs9
45 lines (39 loc) · 1.85 KB
/
Dockerfile.cs9
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
FROM registry.ci.openshift.org/openshift/release:golang-1.17 AS builder
WORKDIR /root
COPY . .
RUN make build
FROM quay.io/centos/centos:stream9
COPY --from=builder /root/_output/ptrp /usr/local/bin/
WORKDIR /root
# Automatically quit if the time of a test run exceeds 3x the average time it normally takes the particular test to complete its run.
ENV TEST_TIMEOUT_AFTER=auto
ARG ARCH
ARG PTS_TEST_SUITE
ARG INSTALL_PKGS=" \
expect strace tmux rpm-build procps-ng dnf-utils rsync \
php-cli php-xml php-json unzip \
cmake perl perl-CPAN cmake-filesystem pkg-config ncurses-devel libtool \
libassuan-devel xz time npth-devel \
"
# phoronix-test-suite.xml with settings for running tests in a batch mode.
# Helper scripts and opinionated test-suites included.
COPY ./assets/linux/all/ /
COPY ./assets/linux/$ARCH/ /
# For tzdata reinstall, see rhbz#2047185 and rhbz#2070567
RUN dnf install -y --setopt=tsflags=nodocs epel-release dnf-plugins-core && \
dnf config-manager --set-enabled crb && \
dnf install -y --setopt=tsflags=nodocs $INSTALL_PKGS && \
dnf reinstall -y --setopt=tsflags=nodocs tzdata && \
curl -LO https://kojipkgs.fedoraproject.org/packages/google-benchmark/1.5.4/1.fc34/src/google-benchmark-1.5.4-1.fc34.src.rpm && \
yum-builddep -y *.rpm && rpmbuild --rebuild *.rpm && \
dnf install -y --setopt=tsflags=nodocs /root/rpmbuild/RPMS/$(arch)/google-benchmark-*.rpm && \
curl -LO https://phoronix-test-suite.com/releases/phoronix-test-suite-10.8.3.tar.gz && \
tar xvf *.gz && \
cd phoronix-test-suite/ && \
mv pts-core/objects/pts_openbenchmarking_upload.php{,.disabled} && \
for ts in $PTS_TEST_SUITE; do \
./phoronix-test-suite install-dependencies $ts && \
./phoronix-test-suite install $ts; \
done && \
dnf clean all && \
rm -rf /root/{rpmbuild,*.rpm,*.tar.gz} /var/cache/yum