diff --git a/.dockerignore b/.dockerignore index 3d1deed..c4dfb92 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,6 +1,6 @@ * !assets -!Dockerfile -!Dockerfile-* +!Dockerfile* !SOLUTION !MANIFEST +Dockerfile.solution* diff --git a/Dockerfile b/Dockerfile index df4447d..64742e8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -132,7 +132,7 @@ RUN echo "deb [trusted=yes arch=amd64] https://osgc.jf.intel.com/internal/ubuntu # -# Template from templates/ubuntu/25-graphics-user.in +# Template from templates/ubuntu/25-create-user.in # # Create user 'user' and add them to 'sudo' for sudo access and set # the passwd to 'user' @@ -150,7 +150,7 @@ RUN groupadd -r user \ -s /bin/bash \ -r -m \ -g user \ - -G sudo \ + -G sudo,video \ -p $(echo "user" | openssl passwd -stdin) user # Set 'sudo' to NOPASSWD for all container users diff --git a/Dockerfile.rhel-8.0 b/Dockerfile.rhel-8.0 index dcc170a..31491a4 100644 --- a/Dockerfile.rhel-8.0 +++ b/Dockerfile.rhel-8.0 @@ -48,11 +48,9 @@ RUN { \ echo "no_proxy=${no_proxy}" ; \ } | tee -a /etc/dnf/dnf.conf /etc/yum.conf - # # Template from templates/rhel/10-rhel-partner.in # - # Remove any pre-configured repositories RUN rm -rf /etc/yum.repos.d/* @@ -214,6 +212,16 @@ RUN { \ echo "" ; \ } > /etc/yum.repos.d/RHEL-8-rt-intel-partner.repo +# +# Template from templates/rhel/15-upgrade.in +# +# Update package lists, and upgrade to the latest packages +# +# Failure to do this will result in GPG errors later +RUN dnf clean all \ + && dnf -y upgrade + + # # Template from templates/rhel/20-repositories-intel-com.in # @@ -236,14 +244,14 @@ RUN { \ RUN { \ echo "[intel-graphics]" ; \ echo "name=Intel Graphics Drivers Repository" ; \ - echo "baseurl=https://repositories.intel.com/graphics/rhel/8.0/" ; \ + echo "baseurl=https://osgc.jf.intel.com/internal/rhel/8.0/" ; \ echo "sslverify=0" ; \ echo "enabled=1" ; \ echo "gpgcheck=0" ; \ } > /etc/yum.repos.d/intel-graphics.repo # -# Template from templates/rhel/25-graphics-user.in +# Template from templates/rhel/25-create-user.in # # Create user 'user' and add them to 'sudo' for sudo access and set # the passwd to 'user' @@ -258,11 +266,11 @@ RUN groupadd -r user \ -s /bin/bash \ -r -m \ -g user \ - -G sudo \ + -G wheel,video \ -p $(echo "user" | openssl passwd -stdin) user -# Set 'sudo' to NOPASSWD for all container users -RUN sed -i -e 's,%sudo.*,%sudo ALL=(ALL) NOPASSWD:ALL,g' /etc/sudoers +# Set 'wheel' to NOPASSWD for all container users +RUN sed -i -e 's,%wheel.*,%wheel ALL=(ALL) NOPASSWD:ALL,g' /etc/sudoers USER user @@ -351,13 +359,6 @@ ENTRYPOINT [ "/assets/entry" ] # Ensure that each Docker container self-documents the # versions included in it - -RUN { \ - echo "PACKAGE_REPOSITORY=https://repositories.intel.com/graphics" ; \ - echo "RELEASE_INFO=N/A" ; \ - echo "PACKAGE_STREAM=8.0" ; \ - echo "OS_DISTRO=rhel" ; \ - echo "OS_RELEASE=8.0" ; \ -} | sudo tee /assets/SOLUTION +COPY SOLUTION /assets/ COPY MANIFEST /assets/ COPY Dockerfile.rhel-8.0 /assets/Dockerfile diff --git a/templates/centos/25-create-user.in b/templates/centos/25-create-user.in index dd03c45..0ef9ba3 100644 --- a/templates/centos/25-create-user.in +++ b/templates/centos/25-create-user.in @@ -11,7 +11,7 @@ RUN groupadd -r user \ -s /bin/bash \ -r -m \ -g user \ - -G wheel \ + -G wheel,video \ -p $(echo "user" | openssl passwd -stdin) user # Set 'wheel' to NOPASSWD for all container users diff --git a/templates/rhel/25-create-user.in b/templates/rhel/25-create-user.in index f2fecdd..508db9d 100644 --- a/templates/rhel/25-create-user.in +++ b/templates/rhel/25-create-user.in @@ -11,7 +11,7 @@ RUN groupadd -r user \ -s /bin/bash \ -r -m \ -g user \ - -G wheel \ + -G wheel,video \ -p $(echo "user" | openssl passwd -stdin) user # Set 'wheel' to NOPASSWD for all container users diff --git a/templates/ubuntu/25-graphics-user.in b/templates/ubuntu/25-create-user.in similarity index 97% rename from templates/ubuntu/25-graphics-user.in rename to templates/ubuntu/25-create-user.in index 1c15620..4410873 100644 --- a/templates/ubuntu/25-graphics-user.in +++ b/templates/ubuntu/25-create-user.in @@ -14,7 +14,7 @@ RUN groupadd -r user \ -s /bin/bash \ -r -m \ -g user \ - -G sudo \ + -G sudo,video \ -p $(echo "user" | openssl passwd -stdin) user # Set 'sudo' to NOPASSWD for all container users