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

Non-errors passed to stderr? #118

Open
Vel1khan opened this issue Jun 15, 2023 · 1 comment
Open

Non-errors passed to stderr? #118

Vel1khan opened this issue Jun 15, 2023 · 1 comment

Comments

@Vel1khan
Copy link
Contributor

Vel1khan commented Jun 15, 2023

I noticed that there might be some junk written to stderr. Not sure if this is intended behaviour, but it makes it difficult to pinpoint the source of an error when programatically building the packages. Whether the build succeeds or fails, there seem to be docker and dos2unix logs written.

See below:

Build Success

HEAD is now at a7d211f gpg keys
#1 [internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.0s

#2 [internal] load build definition from Dockerfile-rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8
#2 transferring dockerfile: 4.33kB done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/library/ubuntu:22.04
#3 DONE 0.4s

#4 [ 1/15] FROM docker.io/library/ubuntu:22.04@sha256:ac58ff7fe25edc58bdf0067ca99df00014dbd032e2246d30a722fa348fd799a5
#4 DONE 0.0s

#5 [12/15] RUN cd /usr/local/ && tar xzf apache-maven-3.6.3-bin.tar.gz --strip-components 1 -C /usr/local/apache-maven
#5 CACHED

#6 [14/15] RUN sed -i '/^plugin mozilla-javaplugin.so.*$/d' /usr/lib/jvm/.java-*
#6 CACHED

#7 [ 8/15] RUN apt-get -q install -y --no-install-recommends      openjdk-8-jdk
#7 CACHED

#8 [ 6/15] RUN apt clean cache    && apt-get -q update    && apt-get install -y software-properties-common apt-utils apt-transport-https ca-certificates
#8 CACHED

#9 [10/15] RUN mkdir -p /usr/local/apache-maven
#9 CACHED

#10 [ 7/15] RUN apt-get -q install -y --no-install-recommends     bash-completion     build-essential     bzip2     wget     curl     docker.io     git     gnupg-agent     rsync     sudo     vim     locales     wget     time     ruby     tzdata     diffoscope     procyon-decompiler     python3-tlsh     tlsh-tools     unzip     less
#10 CACHED

#11 [ 4/15] RUN echo APT::Install-Suggests "0"; >>  /etc/apt/apt.conf.d/10disableextras
#11 CACHED

#12 [ 3/15] RUN echo APT::Install-Recommends "0"; > /etc/apt/apt.conf.d/10disableextras
#12 CACHED

#13 [13/15] RUN ln -s /usr/local/apache-maven/bin/mvn /usr/bin/mvn
#13 CACHED

#14 [11/15] RUN cd /usr/local/ && wget "https://www.apache.org/dyn/closer.lua?action=download&filename=/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.tar.gz" -O "apache-maven-3.6.3-bin.tar.gz"
#14 CACHED

#15 [ 2/15] WORKDIR /root
#15 CACHED

#16 [ 5/15] RUN sed -i 's@^\(deb http://security.ubuntu.com\)@# -------- Disabled because of 404 problems #\1@' /etc/apt/sources.list
#16 CACHED

#17 [ 9/15] RUN ln -fs /usr/share/zoneinfo/Australia/Eucla /etc/localtime &&     dpkg-reconfigure -f noninteractive tzdata
#17 CACHED

#18 [15/15] RUN update-java-alternatives --set "$(update-java-alternatives -l | fgrep "8" | sed 's@ \+@ @g' | cut -d' ' -f1)"
#18 CACHED

#19 exporting to image
#19 exporting layers done
#19 writing image sha256:b8d0ea832680a5f0997bfd8c30178939bd74bf0551221405cad945544c9c64fa done
#19 naming to docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8 done
#19 DONE 0.0s
#1 [internal] load build definition from Dockerfile-rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor
#1 transferring dockerfile: 1.20kB done
#1 DONE 0.0s

#2 [internal] load .dockerignore
#2 transferring context: 2B done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8:latest
#3 DONE 0.0s

#4 [ 1/10] FROM docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8
#4 DONE 0.0s

#5 [internal] load build context
#5 transferring context: 313B done
#5 DONE 0.0s

#6 [ 8/10] RUN mkdir -p /var/maven/.m2
#6 CACHED

#7 [ 5/10] ADD includes/logging.sh /scripts/
#7 CACHED

#8 [ 2/10] RUN [ -d /scripts ] || mkdir /scripts
#8 CACHED

#9 [ 3/10] ADD docker/*.sh /scripts/
#9 CACHED

#10 [ 4/10] ADD includes/bashcolors.sh /scripts/
#10 CACHED

#11 [ 6/10] RUN chmod 755 /scripts/*.sh
#11 CACHED

#12 [ 9/10] RUN /scripts/generate-toolchains.sh > /var/maven/.m2/toolchains.xml
#12 CACHED

#13 [ 7/10] RUN /scripts/configure-for-user.sh "tudor" "1000" "1000" "$(grep -F vboxsf /etc/group)"
#13 CACHED

#14 [10/10] RUN chown -R 1000:1000 /var/maven/.m2
#14 CACHED

#15 exporting to image
#15 exporting layers done
#15 writing image sha256:62d2a755782a9de706adb83473e180f4cba4f259d10b2d58ab77cee0403fc271 done
#15 naming to docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor done
#15 DONE 0.0s
#1 [internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.0s

#2 [internal] load build definition from Dockerfile-rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor-utc-en_us-0002
#2 transferring dockerfile: 1.97kB done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor:latest
#3 DONE 0.0s

#4 [ 1/13] FROM docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor
#4 DONE 0.0s

#5 [internal] load build context
#5 transferring context: 853B done
#5 DONE 0.0s

#6 [ 6/13] ADD includes/logging.sh /scripts/
#6 CACHED

#7 [ 4/13] ADD docker/*.sh /scripts/
#7 CACHED

#8 [ 5/13] ADD includes/bashcolors.sh /scripts/
#8 CACHED

#9 [ 3/13] RUN [ -d /scripts ] || mkdir /scripts
#9 CACHED

#10 [12/13] RUN cat /etc/timezone
#10 CACHED

#11 [11/13] RUN ln -fs /usr/share/zoneinfo/UTC /etc/localtime &&     dpkg-reconfigure -f noninteractive tzdata
#11 CACHED

#12 [ 2/13] WORKDIR /root
#12 CACHED

#13 [ 8/13] ADD docker/mvn /usr/local/bin
#13 CACHED

#14 [ 9/13] RUN chmod 755 /usr/local/bin/mvn
#14 CACHED

#15 [ 7/13] RUN chmod 755 /scripts/*.sh
#15 CACHED

#16 [10/13] RUN [ -f /etc/locale.gen ] && sed -i "/en_US.UTF-8/s/^# //g" /etc/locale.gen && locale-gen || true
#16 CACHED

#17 [13/13] RUN ls -laF /etc/localtime
#17 CACHED

#18 exporting to image
#18 exporting layers done
#18 writing image sha256:af522a7fe80eeaea5c7e9a63cd32ebc4bc8d9c66f4b4e43b9b709914532007d5 done
#18 naming to docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor-utc-en_us-0002 done
#18 DONE 0.0s
dos2unix: converting file target/reproducible-build-maven-plugin-0.15.1.buildinfo to Unix format...
dos2unix: converting file target/reproducible-build-maven-plugin-0.15.1.buildcompare to Unix format...

Build Fail

HEAD is now at 395df42a0 [INLONG-1505] fix dependencies error when build release-0.10.0 (#1506)
#1 [internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.0s

#2 [internal] load build definition from Dockerfile-rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8
#2 transferring dockerfile: 4.33kB done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/library/ubuntu:22.04
#3 DONE 0.2s

#4 [ 1/15] FROM docker.io/library/ubuntu:22.04@sha256:ac58ff7fe25edc58bdf0067ca99df00014dbd032e2246d30a722fa348fd799a5
#4 DONE 0.0s

#5 [ 7/15] RUN apt-get -q install -y --no-install-recommends     bash-completion     build-essential     bzip2     wget     curl     docker.io     git     gnupg-agent     rsync     sudo     vim     locales     wget     time     ruby     tzdata     diffoscope     procyon-decompiler     python3-tlsh     tlsh-tools     unzip     less
#5 CACHED

#6 [11/15] RUN cd /usr/local/ && wget "https://www.apache.org/dyn/closer.lua?action=download&filename=/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.tar.gz" -O "apache-maven-3.6.3-bin.tar.gz"
#6 CACHED

#7 [ 8/15] RUN apt-get -q install -y --no-install-recommends      openjdk-8-jdk
#7 CACHED

#8 [ 5/15] RUN sed -i 's@^\(deb http://security.ubuntu.com\)@# -------- Disabled because of 404 problems #\1@' /etc/apt/sources.list
#8 CACHED

#9 [12/15] RUN cd /usr/local/ && tar xzf apache-maven-3.6.3-bin.tar.gz --strip-components 1 -C /usr/local/apache-maven
#9 CACHED

#10 [ 9/15] RUN ln -fs /usr/share/zoneinfo/Australia/Eucla /etc/localtime &&     dpkg-reconfigure -f noninteractive tzdata
#10 CACHED

#11 [13/15] RUN ln -s /usr/local/apache-maven/bin/mvn /usr/bin/mvn
#11 CACHED

#12 [ 4/15] RUN echo APT::Install-Suggests "0"; >>  /etc/apt/apt.conf.d/10disableextras
#12 CACHED

#13 [ 3/15] RUN echo APT::Install-Recommends "0"; > /etc/apt/apt.conf.d/10disableextras
#13 CACHED

#14 [14/15] RUN sed -i '/^plugin mozilla-javaplugin.so.*$/d' /usr/lib/jvm/.java-*
#14 CACHED

#15 [ 2/15] WORKDIR /root
#15 CACHED

#16 [ 6/15] RUN apt clean cache    && apt-get -q update    && apt-get install -y software-properties-common apt-utils apt-transport-https ca-certificates
#16 CACHED

#17 [10/15] RUN mkdir -p /usr/local/apache-maven
#17 CACHED

#18 [15/15] RUN update-java-alternatives --set "$(update-java-alternatives -l | fgrep "8" | sed 's@ \+@ @g' | cut -d' ' -f1)"
#18 CACHED

#19 exporting to image
#19 exporting layers done
#19 writing image sha256:b8d0ea832680a5f0997bfd8c30178939bd74bf0551221405cad945544c9c64fa done
#19 naming to docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8 done
#19 DONE 0.0s
#1 [internal] load .dockerignore
#1 DONE 0.0s

#1 [internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.0s

#2 [internal] load build definition from Dockerfile-rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor
#2 transferring dockerfile: 1.20kB done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8:latest
#3 DONE 0.0s

#4 [ 1/10] FROM docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8
#4 DONE 0.0s

#5 [internal] load build context
#5 transferring context: 313B done
#5 DONE 0.0s

#6 [ 8/10] RUN mkdir -p /var/maven/.m2
#6 CACHED

#7 [ 6/10] RUN chmod 755 /scripts/*.sh
#7 CACHED

#8 [ 2/10] RUN [ -d /scripts ] || mkdir /scripts
#8 CACHED

#9 [ 3/10] ADD docker/*.sh /scripts/
#9 CACHED

#10 [ 5/10] ADD includes/logging.sh /scripts/
#10 CACHED

#11 [ 7/10] RUN /scripts/configure-for-user.sh "tudor" "1000" "1000" "$(grep -F vboxsf /etc/group)"
#11 CACHED

#12 [ 4/10] ADD includes/bashcolors.sh /scripts/
#12 CACHED

#13 [ 9/10] RUN /scripts/generate-toolchains.sh > /var/maven/.m2/toolchains.xml
#13 CACHED

#14 [10/10] RUN chown -R 1000:1000 /var/maven/.m2
#14 CACHED

#15 exporting to image
#15 exporting layers done
#15 writing image sha256:62d2a755782a9de706adb83473e180f4cba4f259d10b2d58ab77cee0403fc271 done
#15 naming to docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor done
#15 DONE 0.0s
#1 [internal] load build definition from Dockerfile-rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor-utc-en_us-0002
#1 transferring dockerfile: 1.97kB done
#1 DONE 0.0s

#2 [internal] load .dockerignore
#2 transferring context: 2B done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor:latest
#3 DONE 0.0s

#4 [ 1/13] FROM docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor
#4 DONE 0.0s

#5 [internal] load build context
#5 transferring context: 853B done
#5 DONE 0.0s

#6 [ 2/13] WORKDIR /root
#6 CACHED

#7 [ 6/13] ADD includes/logging.sh /scripts/
#7 CACHED

#8 [ 4/13] ADD docker/*.sh /scripts/
#8 CACHED

#9 [11/13] RUN ln -fs /usr/share/zoneinfo/UTC /etc/localtime &&     dpkg-reconfigure -f noninteractive tzdata
#9 CACHED

#10 [ 3/13] RUN [ -d /scripts ] || mkdir /scripts
#10 CACHED

#11 [12/13] RUN cat /etc/timezone
#11 CACHED

#12 [10/13] RUN [ -f /etc/locale.gen ] && sed -i "/en_US.UTF-8/s/^# //g" /etc/locale.gen && locale-gen || true
#12 CACHED

#13 [ 5/13] ADD includes/bashcolors.sh /scripts/
#13 CACHED

#14 [ 8/13] ADD docker/mvn /usr/local/bin
#14 CACHED

#15 [ 9/13] RUN chmod 755 /usr/local/bin/mvn
#15 CACHED

#16 [ 7/13] RUN chmod 755 /scripts/*.sh
#16 CACHED

#17 [13/13] RUN ls -laF /etc/localtime
#17 CACHED

#18 exporting to image
#18 exporting layers done
#18 writing image sha256:af522a7fe80eeaea5c7e9a63cd32ebc4bc8d9c66f4b4e43b9b709914532007d5 done
#18 naming to docker.io/library/rb-ubuntu-2204-jdk8-mvn3.6.3-toolchains-8-tudor-utc-en_us-0002 done
#18 DONE 0.0s

[FAIL] /========================================================================
[FAIL] |  failed to build 
[FAIL] \========================================================================
[FAIL]  ---------->>> PROCESS WAS ABORTED <<<---------- 

@hboutemy
Copy link
Member

I confirm I never really thought at clearly defining a strategy between stdout and stderr: I use rebuild;sh in interactive mode

if you have some changes to propose to the scripts to switch some commands output destination, don't hesitate to provide PRs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants