From be51ba6e13b4c9a2068dcdc2a2b03a47420a51a8 Mon Sep 17 00:00:00 2001 From: "Arnaud G. GIBERT" Date: Tue, 27 Aug 2024 00:24:39 +0200 Subject: [PATCH] - Minor compose / dockerfile args & structur improvements. --- .env | 8 ++++---- Dockerfile | 42 +++++++++++++++++++++++++++++------------- ReleaseNotes.txt | 20 ++++++++++++++------ compose.yaml | 6 +++--- 4 files changed, 50 insertions(+), 26 deletions(-) diff --git a/.env b/.env index b0c9531..8f05b46 100644 --- a/.env +++ b/.env @@ -15,10 +15,10 @@ IMG_URL_PREFIX="${IMG_REGISTRY}/${IMG_ORG}" # Image Settings #------------------------------------------------------------------------------- -IMG_ID="base-mga9" -IMG_NAME="Rx3 Base Mageia-9 Docker Image" -IMG_VERSION="1.2.2" -IMG_URL="${IMG_URL_PREFIX}/${IMG_ID}:${IMG_VERSION}" +IMG_NAME="base-mga9" +IMG_FULL_NAME="Rx3 Base Mageia-9 Docker Image" +IMG_VERSION="1.2.3" +IMG_URL="${IMG_URL_PREFIX}/${IMG_NAME}:${IMG_VERSION}" IMG_MAINTAINER='"Arnaud G. GIBERT" ' diff --git a/Dockerfile b/Dockerfile index bd8de29..fbf54bc 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,29 +8,45 @@ ARG LANGUAGE ARG LOCALTIME -RUN echo -e "LANG=${LANG}\nLANGUAGE=${LANGUAGE}" >/etc/locale.conf \ - && ln -s /usr/share/zoneinfo/${LOCALTIME} /etc/localtime \ - && urpmi.removemedia -a \ - && urpmi.addmedia --distrib http://ftp.free.fr/mirrors/mageia.org/distrib/9/x86_64 \ + +#--------------------------------------------------------------------------------------------------- +ARG LOCALE_CONF="LANG=${LANG} \n\ +LANGUAGE=${LANGUAGE}" +#--------------------------------------------------------------------------------------------------- + +#--------------------------------------------------------------------------------------------------- +ARG RX3_SH='export PAGER=less \n\ +export MANPAGER="less -isr" \n\ +export EDITOR=emacs \n\ +alias ll="ls -la" \n\ +alias em="emacs"' +#--------------------------------------------------------------------------------------------------- + + + +RUN echo -e "${LOCALE_CONF}" | sed -e 's/ *$//' > /etc/locale.conf \ + && ln -s /usr/share/zoneinfo/${LOCALTIME} /etc/localtime \ + && urpmi.removemedia -a \ + && urpmi.addmedia --distrib http://ftp.free.fr/mirrors/mageia.org/distrib/9/x86_64 \ && urpmi.update --no-ignore "Nonfree Release" "Nonfree Updates" "Tainted Release" "Tainted Updates" \ - && urpmi.update -a \ - && urpmi --force --replacepkgs glibc locales locales-en \ - && urpmi --force --auto-update \ - && rm -f /var/log/dnf* /var/log/hawkey.log \ - && echo -e "export PAGER=less\nexport MANPAGER='less -isr'\nexport EDITOR=emacs\nalias ll='ls -la'\nalias em='emacs'" >/etc/profile.d/rx3.sh + && urpmi.update -a \ + && urpmi --force --replacepkgs glibc locales locales-en \ + && urpmi --force --auto-update \ + && rm -f /var/log/dnf* /var/log/hawkey.log \ + && echo -e "${RX3_SH}" | sed -e 's/ *$//' >/etc/profile.d/rx3.sh FROM scratch -ARG IMG_ID ARG IMG_NAME +ARG IMG_FULL_NAME ARG IMG_VERSION ARG IMG_MAINTAINER -LABEL org.rx3.${IMG_ID}.name=${IMG_NAME} -LABEL org.rx3.${IMG_ID}.version=${IMG_VERSION} -LABEL org.rx3.${IMG_ID}.maintainer=${IMG_MAINTAINER} +LABEL org.rx3.${IMG_NAME}.name=${IMG_FULL_NAME} +LABEL org.rx3.${IMG_NAME}.version=${IMG_VERSION} +LABEL org.rx3.${IMG_NAME}.maintainer=${IMG_MAINTAINER} LABEL maintainer=${IMG_MAINTAINER} diff --git a/ReleaseNotes.txt b/ReleaseNotes.txt index d05c237..6ce31c9 100644 --- a/ReleaseNotes.txt +++ b/ReleaseNotes.txt @@ -1,14 +1,22 @@ ------------------------------------------------------------------------------------------------------------------------------------ -Base-Mga9 V 1.2.2 - A. GIBERT - 2024/08/25 +Rx3/Base-Mga9 V 1.2.3 - A. GIBERT - 2024/08/27 +------------------------------------------------------------------------------------------------------------------------------------ + +- Minor compose / dockerfile args & structur improvements. + + + +------------------------------------------------------------------------------------------------------------------------------------ +Rx3/Base-Mga9 V 1.2.2 - A. GIBERT - 2024/08/25 ------------------------------------------------------------------------------------------------------------------------------------ - Remove entrypoint now implemented by rx3/server-mga9 image, -- Minor compose / dockerfile args improvments. +- Minor compose / dockerfile args improvements. ------------------------------------------------------------------------------------------------------------------------------------ -Base-Mga9 V 1.2.1 - A. GIBERT - 2024/08/24 +Rx3/Base-Mga9 V 1.2.1 - A. GIBERT - 2024/08/24 ------------------------------------------------------------------------------------------------------------------------------------ - Add LANG, LANGUAGE & LOCALTIME build args, @@ -17,7 +25,7 @@ Base-Mga9 V 1.2.1 - A. GIBERT - 2024/08/24 ------------------------------------------------------------------------------------------------------------------------------------ -Base-Mga9 V 1.2.0 - A. GIBERT - 2024/08/22 +Rx3/Base-Mga9 V 1.2.0 - A. GIBERT - 2024/08/22 ------------------------------------------------------------------------------------------------------------------------------------ - Mono Layer release whith multi-stage building, @@ -28,7 +36,7 @@ Base-Mga9 V 1.2.0 - A. GIBERT - 2024/08/22 ------------------------------------------------------------------------------------------------------------------------------------ -Base-Mga9 V 1.1.0 - A. GIBERT - 2024/08/22 +Rx3/Base-Mga9 V 1.1.0 - A. GIBERT - 2024/08/22 ----------------------------------------------------------------------------------------------------------------------------------- - Mono Layer release: manually merged by docker export + copy. @@ -36,7 +44,7 @@ Base-Mga9 V 1.1.0 - A. GIBERT - 2024/08/22 ------------------------------------------------------------------------------------------------------------------------------------ -Base-Mga9 V 1.0.0 - A. GIBERT - 2024/08/22 +Rx3/Base-Mga9 V 1.0.0 - A. GIBERT - 2024/08/22 ------------------------------------------------------------------------------------------------------------------------------------ - Initial release, diff --git a/compose.yaml b/compose.yaml index d217b0e..069905d 100644 --- a/compose.yaml +++ b/compose.yaml @@ -1,20 +1,20 @@ # Rx3 Base Mageia-9 Docker Image #------------------------------------------------------------------------------- -name: ${IMG_ID} +name: ${IMG_NAME} services: default: - container_name: ${IMG_ID} + container_name: ${IMG_NAME} image: ${IMG_URL} build: context: . args: - - IMG_ID=${IMG_ID} - IMG_NAME=${IMG_NAME} + - IMG_FULL_NAME=${IMG_FULL_NAME} - IMG_VERSION=${IMG_VERSION} - IMG_MAINTAINER=${IMG_MAINTAINER} - LANG=${LANG}