diff --git a/lazyDir/centos6.Dockerfile b/lazyDir/centos6.Dockerfile index 812089c..2b2f6fc 100644 --- a/lazyDir/centos6.Dockerfile +++ b/lazyDir/centos6.Dockerfile @@ -17,67 +17,58 @@ # limitations under the License. # +############################## +# General level requirements # +############################## + # Pull base image from official repo -FROM centos:centos6.10 +FROM centos:centos6.11 # Import local GPG keys and enable epel repo -RUN rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6 && \ +RUN rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7 && \ yum -q clean expire-cache && \ yum -q makecache && \ yum -y install --setopt=tsflags=nodocs \ epel-release \ && \ - rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6 && \ + rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7 && \ yum -q -y clean all --enablerepo='*' # Install common requirements -RUN yum -q clean expire-cache && \ +RUN INSTALL_PKGS="git unzip wget which" && \ + yum -q clean expire-cache && \ yum -q makecache && \ - yum -y install --setopt=tsflags=nodocs \ - git \ - unzip \ - wget \ - which \ - && \ + yum -y install --setopt=tsflags=nodocs $INSTALL_PKGS && \ + rpm -V $INSTALL_PKGS && \ yum -q -y clean all --enablerepo='*' -# Enable Software Collections -RUN yum -q clean expire-cache && \ - yum -q makecache && \ - yum -y install --setopt=tsflags=nodocs \ - centos-release-scl \ - scl-utils-build \ - && \ - rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo && \ - yum -q -y clean all --enablerepo='*' +# Prepare locales +ARG locale=en_US.UTF-8 +ENV LANG "${locale}" +ENV LC_ALL "${locale}" -# Import extra GPG keys -RUN rpm --import http://yum.puppetlabs.com/RPM-GPG-KEY-puppet && \ - rpm --import http://yum.puppetlabs.com/RPM-GPG-KEY-puppetlabs && \ - rpm --import http://yum.mariadb.org/RPM-GPG-KEY-MariaDB +# Configure desired timezone +ENV TZ=Europe/Amsterdam +RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \ + echo $TZ > /etc/timezone -# Add internal CA -RUN wget -q https://share.qiy.nl/public/certs/ca-digital-me-private-2026.crt -O /etc/pki/ca-trust/source/anchors/ca-digital-me-internal.pem && \ - update-ca-trust force-enable && \ - update-ca-trust extract - -# Configure global Yum repos -RUN rm -rf /var/cache/yum/* && \ - rm -f /etc/yum.repos.d/*.repo && \ - echo '[all]' > /etc/yum.repos.d/all.repo && \ - echo 'name=Private - centos6-x86_64 - All' >> /etc/yum.repos.d/all.repo && \ - echo 'baseurl=https://mrepo.boxtel/mrepo/testci/centos6-x86_64/RPMS.all' >> /etc/yum.repos.d/all.repo && \ - echo 'enabled=1' >> /etc/yum.repos.d/all.repo +################################## +# Application level requirements # +################################## # Install something and its requirements -#RUN yum -q clean expire-cache && \ +#RUN INSTALL_PKGS="xxx" && \ +# yum -q clean expire-cache && \ # yum -q makecache && \ -# yum -y install --setopt=tsflags=nodocs \ -# ... -# && \ +# yum -y install --setopt=tsflags=nodocs $INSTALL_PKGS && \ +# rpm -V $INSTALL_PKGS && \ # yum -q -y clean all --enablerepo='*' -# Add a dummy user +########################### +# User level requirements # +########################### + +# Parameters for default user:group ARG uid=1000 ARG user=dummy ARG gid=1000 diff --git a/lazyDir/centos7.Dockerfile b/lazyDir/centos7.Dockerfile index 343f350..f671b8c 100644 --- a/lazyDir/centos7.Dockerfile +++ b/lazyDir/centos7.Dockerfile @@ -17,8 +17,12 @@ # limitations under the License. # +############################## +# General level requirements # +############################## + # Pull base image from official repo -FROM centos:centos7.8.2003 +FROM centos:centos7.9.2009 # Import local GPG keys and enable epel repo RUN rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7 && \ @@ -31,53 +35,40 @@ yum -q -y clean all --enablerepo='*' # Install common requirements -RUN yum -q clean expire-cache && \ +RUN INSTALL_PKGS="git unzip wget which" && \ + yum -q clean expire-cache && \ yum -q makecache && \ - yum -y install --setopt=tsflags=nodocs \ - git \ - unzip \ - wget \ - which \ - && \ + yum -y install --setopt=tsflags=nodocs $INSTALL_PKGS && \ + rpm -V $INSTALL_PKGS && \ yum -q -y clean all --enablerepo='*' -# Enable Software Collections -RUN yum -q clean expire-cache && \ - yum -q makecache && \ - yum -y install --setopt=tsflags=nodocs \ - centos-release-scl \ - scl-utils-build \ - && \ - rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo && \ - yum -q -y clean all --enablerepo='*' +# Prepare locales +ARG locale=en_US.UTF-8 +ENV LANG "${locale}" +ENV LC_ALL "${locale}" -# Import extra GPG keys -RUN rpm --import http://yum.puppetlabs.com/RPM-GPG-KEY-puppet && \ - rpm --import http://yum.puppetlabs.com/RPM-GPG-KEY-puppetlabs && \ - rpm --import http://yum.mariadb.org/RPM-GPG-KEY-MariaDB +# Configure desired timezone +ENV TZ=Europe/Amsterdam +RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \ + echo $TZ > /etc/timezone -# Add internal CA -RUN wget -q https://share.qiy.nl/public/certs/ca-digital-me-private-2026.crt -O /etc/pki/ca-trust/source/anchors/ca-digital-me-internal.pem && \ - update-ca-trust force-enable && \ - update-ca-trust extract - -# Configure global Yum repos -RUN rm -rf /var/cache/yum/* && \ - rm -f /etc/yum.repos.d/*.repo && \ - echo '[all]' > /etc/yum.repos.d/all.repo && \ - echo 'name=Private - centos7-x86_64 - All' >> /etc/yum.repos.d/all.repo && \ - echo 'baseurl=https://mrepo.boxtel/mrepo/testci/centos7-x86_64/RPMS.all' >> /etc/yum.repos.d/all.repo && \ - echo 'enabled=1' >> /etc/yum.repos.d/all.repo +################################## +# Application level requirements # +################################## # Install something and its requirements -#RUN yum -q clean expire-cache && \ +#RUN INSTALL_PKGS="xxx" && \ +# yum -q clean expire-cache && \ # yum -q makecache && \ -# yum -y install --setopt=tsflags=nodocs \ -# ... -# && \ +# yum -y install --setopt=tsflags=nodocs $INSTALL_PKGS && \ +# rpm -V $INSTALL_PKGS && \ # yum -q -y clean all --enablerepo='*' -# Add a dummy user +########################### +# User level requirements # +########################### + +# Parameters for default user:group ARG uid=1000 ARG user=dummy ARG gid=1000 diff --git a/lazyDir/ubuntu16.Dockerfile b/lazyDir/ubuntu16.Dockerfile index 6a49ea1..0f250f0 100644 --- a/lazyDir/ubuntu16.Dockerfile +++ b/lazyDir/ubuntu16.Dockerfile @@ -17,24 +17,44 @@ # limitations under the License. # +############################## +# General level requirements # +############################## + # Pull base image from official repo FROM ubuntu:16.04 -# Install all current updates -RUN apt-get -y update && \ - apt-get -y dist-upgrade && \ - apt-get clean - # Install common requirements -RUN apt-get -y update && \ - apt-get -y install \ - git \ - unzip \ - wget \ - && \ - apt-get clean +RUN INSTALL_PKGS="git unzip wget" && \ + apt-get -y update && \ + apt-get -y install $INSTALL_PKGS && \ + apt-get clean -# Add user to build and package +# Prepare locales +ARG locale=en_US.UTF-8 +ENV LANG "${locale}" +ENV LC_ALL "${locale}" + +# Configure desired timezone +ENV TZ=Europe/Amsterdam +RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \ + echo $TZ > /etc/timezone + +################################## +# Application level requirements # +################################## + +# Install something and its requirements# Add user to build and package +#RUN INSTALL_PKGS="xxx" && \ +# apt-get -y update && \ +# apt-get -y install $INSTALL_PKGS && \ +# apt-get clean + +########################### +# User level requirements # +########################### + +# Parameters for default user:group ARG uid=1000 ARG user=dummy ARG gid=1000