Commit 45adc5b6 authored by Dominik Charousset's avatar Dominik Charousset

Hook dockerfile-builds into build matrix

parent f688fc50
############################################################
# Dockerfile for Jenkins slave with gcc 7.3
# Based on CentOS 6
############################################################
FROM centos:6
MAINTAINER Jakob Otto
# Install Essentials
RUN yum update -y \
&& yum install -y centos-release-scl \
&& yum install -y epel-release \
&& yum update -y \
&& yum clean all
##################### INSTALL TOOLS ########################
# Install Packages
RUN yum install -y git \
wget \
make \
sudo \
java-1.8.0-openjdk \
RUN yum install -y \
cmake3 \
openssl-devel \
libubsan \
python-pip \
devtoolset-7 \
devtoolset-7-libasan-devel \
devtoolset-7-libubsan-devel \
git \
make \
openssl-devel \
&& yum clean all
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN mkdir /home/jenkins/bin
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Create symlinks to cmake3 binaries in local bin directory.
RUN ln -s /usr/bin/cmake3 /home/jenkins/bin/cmake
RUN ln -s /usr/bin/ctest3 /home/jenkins/bin/ctest
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
ENV CXX=/opt/rh/devtoolset-7/root/usr/bin/g++
############################################################
# Dockerfile for Jenkins slave with gcc 7.3
# Based on CentOS 7
############################################################
FROM centos:7
MAINTAINER Jakob Otto
# Install Essentials
RUN yum update -y \
&& yum install -y centos-release-scl \
&& yum install -y epel-release \
&& yum update -y \
&& yum clean all
##################### INSTALL TOOLS ########################
# Install Packages
RUN yum install -y git \
wget \
make \
sudo \
java-1.8.0-openjdk \
RUN yum install -y \
cmake3 \
openssl-devel \
libubsan \
python-pip \
devtoolset-7 \
devtoolset-7-libasan-devel \
devtoolset-7-libubsan-devel \
git \
make \
openssl-devel \
&& yum clean all
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN mkdir /home/jenkins/bin
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Create symlinks to cmake3 binaries in local bin directory.
RUN ln -s /usr/bin/cmake3 /home/jenkins/bin/cmake
RUN ln -s /usr/bin/ctest3 /home/jenkins/bin/ctest
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
ENV CXX=/opt/rh/devtoolset-7/root/usr/bin/g++
FROM debian:buster
RUN apt update -y && \
apt upgrade -y
RUN apt install -y \
cmake \
g++-8 \
git \
libssl-dev \
make \
&& apt autoclean
ENV CXX=/usr/bin/g++-8
FROM debian:stretch
RUN apt update -y && \
apt upgrade -y
RUN apt install -y \
clang-7 \
cmake \
git \
libssl-dev \
make \
&& apt autoclean
ENV CXX=/usr/bin/clang++-7
############################################################
# Dockerfile for Jenkins slave with gcc 8.3
# Based on Debian Buster
############################################################
FROM debian:buster
MAINTAINER Jakob Otto
# Install Essentials
RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get autoremove -y && \
apt-get autoclean -y
##################### INSTALL TOOLS ########################
# Install Packages
RUN apt-get install -y git \
wget \
openjdk-11-jdk \
cmake \
gcc g++ \
clang \
libssl-dev \
gcovr \
&& apt-get autoclean
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Ubuntu requires this dir to be created
RUN mkdir -p /var/run/sshd
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
############################################################
# Dockerfile for Jenkins slave with clang-4.0
# Based on Debian Jessie
############################################################
FROM debian:jessie
MAINTAINER Jakob Otto
# No official support for Debian Jessie.
RUN echo "deb http://deb.debian.org/debian/ jessie main contrib non-free" > /etc/apt/sources.list \
&& echo "deb-src http://deb.debian.org/debian/ jessie main contrib non-free" >> /etc/apt/sources.list \
&& echo "deb http://security.debian.org/ jessie/updates main contrib non-free" >> /etc/apt/sources.list \
&& echo "deb-src http://security.debian.org/ jessie/updates main contrib non-free" >> /etc/apt/sources.list \
&& echo "deb http://archive.debian.org/debian jessie-backports main" >> /etc/apt/sources.list \
&& echo "deb-src http://archive.debian.org/debian jessie-backports main" >> /etc/apt/sources.list \
&& echo "Acquire::Check-Valid-Until \"false\";" >> /etc/apt/apt.conf
# Install Essentials
RUN apt-get update && \
apt-get upgrade -y && \
apt-get autoremove
##################### INSTALL TOOLS ########################
# Install Packages
RUN apt-get install -y git \
wget \
cmake \
gcc g++ \
clang-4.0 \
libssl-dev \
gcovr \
&& apt-get autoclean
#################### INSTALL JAVA 8 #######################
RUN apt-get update
RUN apt-get install -y -t jessie-backports openjdk-8-jdk
#RUN update-java-alternatives -s java-1.8.0-openjdk-amd64
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# set clang as default compiler
RUN echo "export CXX=clang++-4.0" >> /home/jenkins/.bashrc \
&& echo "export CC=clang-4.0" >> /home/jenkins/.bashrc
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Ubuntu requires this dir to be created
RUN mkdir -p /var/run/sshd
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
############################################################
# Dockerfile for Jenkins slave with clang-4.0
# Based on Debian Stretch
############################################################
FROM debian:stretch
MAINTAINER Raphael Hiesgen
# Install Essentials
RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get autoremove -y && \
apt-get autoclean -y
##################### INSTALL TOOLS ########################
# Install Packages
RUN apt-get install -y git \
wget \
openjdk-8-jdk \
cmake \
gcc g++ \
clang-4.0 \
libssl-dev \
gcovr \
&& apt-get autoclean
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# set clang as default compiler
RUN echo "export CXX=clang++-4.0" >> /home/jenkins/.bashrc \
&& echo "export CC=clang-4.0" >> /home/jenkins/.bashrc
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Ubuntu requires this dir to be created
RUN mkdir -p /var/run/sshd
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
############################################################
# Dockerfile for Jenkins slave with gcc 7
# Based on Fedora 27
############################################################
FROM fedora:27
MAINTAINER Raphael Hiesgen
# Install Essentials
RUN dnf update -y && \
yum clean all
##################### INSTALL TOOLS ########################
# Install Packages
RUN dnf install -y git \
wget \
sudo \
java-9-openjdk \
cmake \
gcc gcc-c++ \
clang \
openssl-devel \
libasan \
libubsan \
gcovr \
&& dnf clean all
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
############################################################
# Dockerfile for Jenkins slave with gcc 8
# Based on Fedora 28
############################################################
FROM fedora:28
MAINTAINER Raphael Hiesgen
# Install Essentials
RUN dnf update -y && \
yum clean all
##################### INSTALL TOOLS ########################
# Install Packages
RUN dnf install -y git \
wget \
make \
sudo \
java-9-openjdk \
cmake \
docker \
kcov \
gcc gcc-c++ \
clang \
openssl-devel \
libasan \
libubsan \
python-pip \
&& dnf clean all
##################### INSTALL GCOVR #######################
RUN pip install --upgrade gcovr
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
########################################################
# Dockerfile for Jenkins slave with gcc 9
# Based on Fedora 30
############################################################
FROM fedora:30
MAINTAINER Raphael Hiesgen
# Install Essentials
RUN dnf update -y && \
yum clean all
##################### INSTALL TOOLS ########################
dnf clean all
# Install Packages
RUN dnf install -y git \
wget \
RUN dnf install -y \
git \
make \
sudo \
java-11-openjdk \
cmake \
docker \
kcov \
gcc gcc-c++ \
clang \
gcc-c++ \
openssl-devel \
libasan \
libubsan \
python-pip \
&& dnf clean all
##################### INSTALL GCOVR #######################
RUN pip install --upgrade gcovr
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
########################################################
# Dockerfile for Jenkins slave with gcc 9
# Based on Fedora 31
############################################################
FROM fedora:31
MAINTAINER Jakob Otto
# Install Essentials
RUN dnf update -y && \
yum clean all
##################### INSTALL TOOLS ########################
dnf clean all
# Install Packages
RUN dnf install -y git \
wget \
RUN dnf install -y \
git \
make \
sudo \
java-11-openjdk \
cmake \
docker \
kcov \
gcc gcc-c++ \
clang \
gcc-c++ \
openssl-devel \
libasan \
libubsan \
python-pip \
&& dnf clean all
##################### INSTALL GCOVR #######################
RUN pip install --upgrade gcovr
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
############################################################
# Dockerfile for Jenkins slave with clang-4.0
# Based on Ubuntu-16.04
############################################################
FROM ubuntu:16.04
MAINTAINER Jakob Otto
# Install Essentials
RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get autoremove -y && \
apt-get autoclean -y
##################### INSTALL TOOLS ########################
RUN apt update -y && \
apt upgrade -y
# Install Packages
RUN apt-get install -y git \
wget \
openjdk-8-jdk \
RUN apt install -y \
clang-8 \
cmake \
gcc g++ \
clang-4.0 \
git \
libssl-dev \
gcovr \
&& apt-get autoclean
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# set clang as default compiler
RUN echo "export CXX=clang++-4.0" >> /home/jenkins/.bashrc \
&& echo "export CC=clang-4.0" >> /home/jenkins/.bashrc
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Ubuntu requires this dir to be created
RUN mkdir -p /var/run/sshd
make \
&& apt autoclean
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
ENV CXX=/usr/bin/clang++-8
############################################################
# Dockerfile for Jenkins slave with gcc 7.4
# Based on Ubuntu 18.04
############################################################
FROM ubuntu:18.04
MAINTAINER Jakob Otto
# Install Essentials
RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get autoremove -y && \
apt-get autoclean -y
##################### INSTALL TOOLS ########################
RUN apt update -y && \
apt upgrade -y
# Install Packages
RUN apt-get install -y git \
wget \
openjdk-11-jdk \
RUN apt install -y \
cmake \
gcc g++ \
clang \
g++-8
git \
libssl-dev \
gcovr \
make \
&& apt-get autoclean
####################### SETUP SSH #########################
# Create Jenkins User
RUN useradd jenkins -m -s /bin/bash
# Setup home for Jenkins
RUN chown -R jenkins /home/jenkins
RUN chgrp -R jenkins /home/jenkins
# Add the jenkins user to sudoers
# RUN echo "jenkins ALL=(ALL) ALL" >> etc/sudoers
# Set Name Servers
# COPY /files/resolv.conf /etc/resolv.conf
# Ubuntu requires this dir to be created
RUN mkdir -p /var/run/sshd
# Expose SSH port and run SSHD
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]
ENV CXX=/usr/bin/g++-8
#!/usr/bin/env groovy
pipeline {
agent {
// Equivalent to "docker build -f Dockerfile.build --build-arg version=1.0.2 ./build/
dockerfile {
dir '.ci/fedora-30'
label 'docker'
}
}
stages {
stage('Build') {
steps {
sh 'uname -r'
sh 'cat /etc/os-release'
checkout scm
}
}
}
}
/*
@Library('caf-continuous-integration') _
@Library('caf-continuous-integration@topic/docker') _
// Default CMake flags for release builds.
defaultReleaseBuildFlags = [
......@@ -48,38 +28,34 @@ config = [
buildMatrix: [
// Various Linux builds for debug and release.
['centos-6', [
tags: ['docker'],
builds: ['debug', 'release'],
tools: ['gcc-7'],
extraDebugFlags: ['CAF_SANITIZERS:STRING=address,undefined'],
]],
['centos-7', [
tags: ['docker'],
builds: ['debug', 'release'],
tools: ['gcc-7'],
extraDebugFlags: ['CAF_SANITIZERS:STRING=address,undefined'],
]],
['ubuntu-16.04', [
tags: ['docker'],
builds: ['debug', 'release'],
tools: ['clang-4'],
]],
['ubuntu-18.04', [
tags: ['docker'],
builds: ['debug', 'release'],
tools: ['gcc-7'],
]],
// On Fedora 28, our debug build also produces the coverage report.
['fedora-28', [
builds: ['debug'],
tools: ['gcc-8'],
// extraSteps: ['coverageReport'], TODO: fix kcov setup
extraFlags: ['BUILD_SHARED_LIBS:BOOL=OFF'],
['fedora-30', [
tags: ['docker'],
builds: ['debug', 'release'],
]],
['fedora-28', [
builds: ['release'],
tools: ['gcc-8'],
['fedora-31', [
tags: ['docker'],
builds: ['debug', 'release'],
]],
// Other UNIX systems.
['macOS', [
builds: ['debug', 'release'],
tools: ['clang'],
extraFlags: [
'OPENSSL_ROOT_DIR=/usr/local/opt/openssl',
'OPENSSL_INCLUDE_DIR=/usr/local/opt/openssl/include',
......@@ -88,7 +64,6 @@ config = [
]],
['FreeBSD', [
builds: ['debug', 'release'],
tools: ['clang'],
extraDebugFlags: ['CAF_SANITIZERS:STRING=address,undefined'],
]],
// Non-UNIX systems.
......@@ -96,7 +71,6 @@ config = [
// TODO: debug build currently broken
//builds: ['debug', 'release'],
builds: ['release'],
tools: ['msvc'],
extraFlags: ['CAF_ENABLE_OPENSSL_MODULE:BOOL=OFF'],
]],
],
......@@ -205,4 +179,3 @@ pipeline {
}
}
}
*/
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment