Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add GCC 11 tooling to CentOS 7/Amazon Linux 2 builders. #303

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions package-builders/Dockerfile.amazonlinux2.v1
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,12 @@
LABEL org.opencontainers.image.description="Package builder image for Netdata official RPM packages for Amazon Linux 2"
LABEL org.opencontainers.image.vendor="Netdata Inc."

ENV VERSION=$VERSION

Check warning on line 9 in package-builders/Dockerfile.amazonlinux2.v1

View workflow job for this annotation

GitHub Actions / Build Check (amazonlinux2, v1)

Variables should be defined before their use

UndefinedVar: Usage of undefined variable '$VERSION' More info: https://docs.docker.com/go/dockerfile/rule/undefined-var/
ENV SENTRY_DSN="https://[email protected]/dummy"

COPY package-builders/centos-7-scl.repo /etc/yum.repos.d/centos-7-scl.repo
COPY package-builders/RPM-GPG-KEY-CentOS-SIG-SCLo /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo

RUN yum update -y && \
yum install -y autoconf \
autoconf-archive \
Expand All @@ -19,6 +22,8 @@
cmake \
cups-devel \
curl \
devtoolset-11-gcc \
devtoolset-11-gcc-c++ \
diffutils \
elfutils-libelf-devel \
findutils \
Expand Down
5 changes: 5 additions & 0 deletions package-builders/Dockerfile.amazonlinux2.v2
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,20 @@
LABEL org.opencontainers.image.description="Package builder image for Netdata official RPM packages for Amazon Linux 2"
LABEL org.opencontainers.image.vendor="Netdata Inc."

ENV VERSION=$VERSION

Check warning on line 9 in package-builders/Dockerfile.amazonlinux2.v2

View workflow job for this annotation

GitHub Actions / Build Check (amazonlinux2, v2)

Variables should be defined before their use

UndefinedVar: Usage of undefined variable '$VERSION' More info: https://docs.docker.com/go/dockerfile/rule/undefined-var/
ENV SENTRY_DSN="https://[email protected]/dummy"

COPY package-builders/centos-7-scl.repo /etc/yum.repos.d/centos-7-scl.repo
COPY package-builders/RPM-GPG-KEY-CentOS-SIG-SCLo /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo

RUN yum update -y && \
yum install -y bison \
bison-devel \
cmake \
cups-devel \
curl \
devtoolset-11-gcc \
devtoolset-11-gcc-c++ \
diffutils \
elfutils-libelf-devel \
findutils \
Expand Down
5 changes: 5 additions & 0 deletions package-builders/Dockerfile.centos7.v1
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,13 @@
LABEL org.opencontainers.image.description="Package builder image for Netdata official RPM packages for CentOS 7"
LABEL org.opencontainers.image.vendor="Netdata Inc."

ENV VERSION=$VERSION

Check warning on line 9 in package-builders/Dockerfile.centos7.v1

View workflow job for this annotation

GitHub Actions / Build Check (centos7, v1)

Variables should be defined before their use

UndefinedVar: Usage of undefined variable '$VERSION' More info: https://docs.docker.com/go/dockerfile/rule/undefined-var/
# Dummy Sentry DSN
ENV SENTRY_DSN="https://[email protected]/dummy"

COPY package-builders/centos-7-scl.repo /etc/yum.repos.d/centos-7-scl.repo
COPY package-builders/RPM-GPG-KEY-CentOS-SIG-SCLo /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo

RUN yum install -y epel-release && \
yum update -y && \
yum install -y autoconf \
Expand All @@ -22,6 +25,7 @@
cmake \
cups-devel \
curl \
devtoolset-11 \
diffutils \
elfutils-libelf-devel \
findutils \
Expand Down Expand Up @@ -66,6 +70,7 @@
c_rehash && \
mkdir -p /root/rpmbuild/BUILD /root/rpmbuild/RPMS /root/rpmbuild/SOURCES /root/rpmbuild/SPECS /root/rpmbuild/SRPMS


# Fetch a newer version of CMake, because the system-provided one is _ancient_.
# The hash is hard-coded here to mitigate the risk of supply-chain attacks.
RUN curl --fail -sSL --connect-timeout 20 --retry 3 --output cmake-linux-$(uname -m).sh \
Expand Down
4 changes: 4 additions & 0 deletions package-builders/Dockerfile.centos7.v2
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,13 @@
LABEL org.opencontainers.image.description="Package builder image for Netdata official RPM packages for CentOS 7"
LABEL org.opencontainers.image.vendor="Netdata Inc."

ENV VERSION=$VERSION

Check warning on line 9 in package-builders/Dockerfile.centos7.v2

View workflow job for this annotation

GitHub Actions / Build Check (centos7, v2)

Variables should be defined before their use

UndefinedVar: Usage of undefined variable '$VERSION' More info: https://docs.docker.com/go/dockerfile/rule/undefined-var/
# Dummy Sentry DSN
ENV SENTRY_DSN="https://[email protected]/dummy"

COPY package-builders/centos-7-scl.repo /etc/yum.repos.d/centos-7-scl.repo
COPY package-builders/RPM-GPG-KEY-CentOS-SIG-SCLo /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo

RUN yum install -y epel-release && \
yum update -y && \
yum install -y bash \
Expand All @@ -18,6 +21,7 @@
cmake \
cups-devel \
curl \
devtoolset-11 \
diffutils \
elfutils-libelf-devel \
findutils \
Expand Down
20 changes: 20 additions & 0 deletions package-builders/RPM-GPG-KEY-CentOS-SIG-SCLo
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v2.0.22 (GNU/Linux)

mQENBFYM/AoBCADR9Q5cb+H5ndx+QkzNBQ88wcD+g112yvnHNlSiBMOnNEGHuKPJ
tujZ+eWXP3K6ucJckT91WxfQ2fxPr9jQ0xpZytcHcZdTfn3vKL9+OwR0npp+qmcz
rK8/EzVz/SWSgBQ5xT/HUvaeoVAbzBHSng0r2njnBAqABKAoTxgyRGKSCWduKD32
7PF2ZpqeDFFhd99Ykt6ar8SlV8ToqH6F7An0ILeejINVbHUxd6+wsbpcOwQ4mGAa
/CPXeqqLGj62ASBv36xQr34hlN/9zQMViaKkacl8zkuvwhuHf4b4VlGVCe6VILpQ
8ytKMV/lcg7YpMfRq4KVWBjCwkvk6zg6KxaHABEBAAG0aENlbnRPUyBTb2Z0d2Fy
ZUNvbGxlY3Rpb25zIFNJRyAoaHR0cHM6Ly93aWtpLmNlbnRvcy5vcmcvU3BlY2lh
bEludGVyZXN0R3JvdXAvU0NMbykgPHNlY3VyaXR5QGNlbnRvcy5vcmc+iQE5BBMB
AgAjBQJWDPwKAhsDBwsJCAcDAgEGFQgCCQoLBBYCAwECHgECF4AACgkQTrhOcfLu
nVXNewgAg7RVclomjTY4w80XiztUuUaFlCHyR76KazdaGfx/8XckWH2GdQtwii+3
Tg7+PT2H0Xyuj1aod+jVTPXTPVUr+rEHAjuNDY+xyAJrNljoOHiz111zs9pk7PLX
CPwKWQLnmrcKIi8v/51L79FFsUMvhClTBdLUQ51lkCwbcXQi+bOhPvZTVbRhjoB/
a9z0d8t65X16zEzE7fBhnVoj4xye/MPMbTH41Mv+FWVciBTuAepOLmgJ9oxODliv
rgZa28IEWkvHQ8m9GLJ0y9mI6olh0cGFybnd5y4Ss1cMttlRGR4qthLhN2gHZpO9
2y4WgkeVXCj1BK1fzVrDMLPbuNNCZQ==
=UtPD
-----END PGP PUBLIC KEY BLOCK-----
15 changes: 15 additions & 0 deletions package-builders/centos-7-scl.repo
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[centos-sclo-sclo]
name=CentOS-7 - SCLo sclo
baseurl=http://vault.centos.org/centos/7.9.2009/sclo/$basearch/sclo/
#mirrorlist=http://mirrorlist.centos.org?arch=$basearch&release=7&repo=sclo-sclo
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo

[centos-sclo-rh]
name=CentOS-7 - SCLo rh
baseurl=http://vault.centos.org/centos/7.9.2009/sclo/$basearch/rh/
#mirrorlist=http://mirrorlist.centos.org?arch=$basearch&release=7&repo=sclo-rh
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo
6 changes: 5 additions & 1 deletion package-builders/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
#!/bin/sh

if [ -e /opt/rh/devtoolset-11/enable ]; then
. /opt/rh/devtoolset-11/enable

Check warning on line 4 in package-builders/entrypoint.sh

View workflow job for this annotation

GitHub Actions / shellcheck

[shellcheck] reported by reviewdog 🐶 Not following: /opt/rh/devtoolset-11/enable: openBinaryFile: does not exist (No such file or directory) Raw Output: ./package-builders/entrypoint.sh:4:7: info: Not following: /opt/rh/devtoolset-11/enable: openBinaryFile: does not exist (No such file or directory) (ShellCheck.SC1091)
fi

if [ -d /cmake/bin ]; then
PATH="/cmake/bin:${PATH}"
fi

if [ -n "$NETDATA_SENTRY_DSN" ]; then
SENTRY_DSN="$NETDATA_SENTRY_DSN"
SENTRY_DSN="$NETDATA_SENTRY_DSN"

Check warning on line 12 in package-builders/entrypoint.sh

View workflow job for this annotation

GitHub Actions / shellcheck

[shellcheck] reported by reviewdog 🐶 SENTRY_DSN appears unused. Verify use (or export if used externally). Raw Output: ./package-builders/entrypoint.sh:12:5: warning: SENTRY_DSN appears unused. Verify use (or export if used externally). (ShellCheck.SC2034)
fi

fail() {
Expand Down
Loading