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

ansible,jenkins: install and use GCC 10 on ubuntu2004_sharedlibs #3485

Merged
merged 4 commits into from
Sep 18, 2023

Conversation

targos
Copy link
Member

@targos targos commented Sep 13, 2023

Refs: #3317

@targos
Copy link
Member Author

targos commented Sep 13, 2023

I'm getting an unrelated error while trying to apply it:

ansible-playbook --limit test-osuosl-ubuntu2004_docker-arm64-1 ansible/playbooks/jenkins/docker-host.yaml
TASK [github : write github.com entry in known_hosts] ************************************************************************************************
fatal: [test-osuosl-ubuntu2004_docker-arm64-1]: FAILED! => {"msg": "Failed to set permissions on the temporary files Ansible needs to create when becoming an unprivileged user (rc: 1, err: chmod: invalid mode: ‘A+user:iojs:rx:allow’\nTry 'chmod --help' for more information.\n}). For information on working around this, see https://docs.ansible.com/ansible-core/2.15/playbook_guide/playbooks_privilege_escalation.html#risks-of-becoming-an-unprivileged-user#risks-of-becoming-an-unprivileged-user"}

I don't know what to do now..

@richardlau
Copy link
Member

I'm seeing the same error too 😞

@richardlau
Copy link
Member

Wonder if it's related to ansible/ansible#79602

It's needed by Ansible to create temporary directories with the correct permissions.
@targos
Copy link
Member Author

targos commented Sep 15, 2023

I confirm that installing acl fixed the issue.

@targos
Copy link
Member Author

targos commented Sep 15, 2023

Docker images are now building.

test-osuosl-centos7_container-arm64-1 already failed with:

Collecting tap2junit==0.1.6", "\u001b[91m  Could not find a version that satisfies the requirement tap2junit==0.1.6 (from versions: 0.0.1, 0.0.2, 0.0.3, 0.0.4, 0.0.5, 0.1.0, 0.1.1, 0.1.2, 0.1.3, 0.1.4, 0.1.5)"

@richardlau
Copy link
Member

Docker images are now building.

test-osuosl-centos7_container-arm64-1 already failed with:

Collecting tap2junit==0.1.6", "\u001b[91m  Could not find a version that satisfies the requirement tap2junit==0.1.6 (from versions: 0.0.1, 0.0.2, 0.0.3, 0.0.4, 0.0.5, 0.1.0, 0.1.1, 0.1.2, 0.1.3, 0.1.4, 0.1.5)"

That is likely related to the version of Python 3 being used. tap2junit 0.1.6 requires Python 3.7: https://pypi.org/project/tap2junit/. I had to use a non-system Python 3 for RHEL 8, for example, #3306.

@targos
Copy link
Member Author

targos commented Sep 15, 2023

There's another broken docker build with test-osuosl-ubuntu1804_sharedlibs_container-arm64-1:

"Step 30/36 : ENV ZLIBVER 1.2.13", " ---> Using cache", " ---> dae1cdad655e", "Step 31/36 : ENV ZLIB12DIR /opt/zlib_$ZLIBVER", " ---> Using cache", " ---> b11991c97718", "Step 32/36 : RUN mkdir -p /tmp/zlib_$ZLIBVER &&     cd /tmp/zlib_$ZLIBVER &&     curl -sL https://zlib.net/zlib-$ZLIBVER.tar.gz | tar zxv --strip=1 &&     ./configure --prefix=$ZLIB12DIR &&     make -j 6 &&     make install &&     rm -rf /tmp/zlib_$ZLIBVER", " ---> Running in 55c89873c059", "\u001b[91m", "gzip: stdin: not in gzip format", "\u001b[0m\u001b[91mtar: Child returned status 1", "tar: Error is not recoverable: exiting now", "\u001b[0m"]}

I'm not sure how to proceed at this point, as the playbook stops because of those two build failures.

@richardlau
Copy link
Member

There's another broken docker build with test-osuosl-ubuntu1804_sharedlibs_container-arm64-1:

"Step 30/36 : ENV ZLIBVER 1.2.13", " ---> Using cache", " ---> dae1cdad655e", "Step 31/36 : ENV ZLIB12DIR /opt/zlib_$ZLIBVER", " ---> Using cache", " ---> b11991c97718", "Step 32/36 : RUN mkdir -p /tmp/zlib_$ZLIBVER &&     cd /tmp/zlib_$ZLIBVER &&     curl -sL https://zlib.net/zlib-$ZLIBVER.tar.gz | tar zxv --strip=1 &&     ./configure --prefix=$ZLIB12DIR &&     make -j 6 &&     make install &&     rm -rf /tmp/zlib_$ZLIBVER", " ---> Running in 55c89873c059", "\u001b[91m", "gzip: stdin: not in gzip format", "\u001b[0m\u001b[91mtar: Child returned status 1", "tar: Error is not recoverable: exiting now", "\u001b[0m"]}

I'm not sure how to proceed at this point, as the playbook stops because of those two build failures.

Ah, this one is #3067 (comment) -- zlib only keep the most recent version available to download from https://zlib.net/ but older ones are available on https://www.zlib.net/fossils/. Apparently I updated the docker templates for the Ubuntu 20.04 sharedlibs containers in https://github.com/nodejs/build/pull/3076/files#diff-12b3498626d53cb9267e5ec7cec164c7bf5a3d703c0239277071edac9f3b69da but not the Ubuntu 18.04 based ones.

@targos if you like I can take a look at fixing the two failing containers today after lunch.

@targos
Copy link
Member Author

targos commented Sep 15, 2023

if you like I can take a look at fixing the two failing containers today after lunch.

That would be awesome. I won't have much more time for this today

Once zlib releases a new version they remove the older one and move it
to https://www.zlib.net/fossils/. Use this more stable URL to fetch the
zlib source when building containers.
Current versions of tap2junit require Python > 3.7. The default
python3 package on CentOS 7 is Python 3.6.
@richardlau
Copy link
Member

richardlau commented Sep 15, 2023

I've pushed two commits to this PR to fix the issues with the CentOS 7 container and Ubuntu 18.04 sharedlibs container.

ansible-playbook --limit test-osuosl-ubuntu2004_docker-arm64-1 ansible/playbooks/jenkins/docker-host.yaml

successfully ran to completion with c73b708.

@targos FYI we might also need to add ICU 73 to the sharedlib containers (either as part of this PR or a follow-up) in preparation for nodejs/node#49639.

Copy link
Member Author

@targos targos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't approve because it's my PR, but @richardlau's commits LGTM. Thanks for the help!

@targos targos merged commit 2e7c763 into nodejs:main Sep 18, 2023
2 checks passed
@targos targos deleted the ubuntu2004-gcc10 branch September 18, 2023 08:58
@targos
Copy link
Member Author

targos commented Sep 20, 2023

@targos
Copy link
Member Author

targos commented Sep 20, 2023

18:08:19 + curl -sLO https://raw.githubusercontent.com/nodejs/build/main/jenkins/scripts/select-compiler.sh
18:08:19 + . ./select-compiler.sh
18:08:19 ++ '[' '' '!=' DONT ']'
18:08:19 ++ NODE_NAME=test-equinix-ubuntu2004_sharedlibs_container-arm64-5
18:08:19 ++ echo 'Selecting compiler based on test-equinix-ubuntu2004_sharedlibs_container-arm64-5'
18:08:19 Selecting compiler based on test-equinix-ubuntu2004_sharedlibs_container-arm64-5
18:08:19 ++ case $NODE_NAME in
18:08:19 ++ SELECT_ARCH=ARM64
18:08:19 ++ '[' -z x ']'
18:08:19 ++ case $NODE_NAME in
18:08:19 ++ '[' ARM64 = PPC64LE ']'
18:08:19 ++ '[' ARM64 = S390X ']'
18:08:19 ++ '[' ARM64 = IBMI73 ']'
18:08:19 ++ '[' ARM64 = AIXPPC ']'
18:08:19 ++ '[' ARM64 = X64 ']'
18:08:19 ++ '[' ARM64 = ARM64 ']'
18:08:19 ++ echo 'Setting compiler for Node version 21 on arm64'
18:08:19 Setting compiler for Node version 21 on arm64
18:08:19 ++ case $nodes in
18:08:19 + export 'CONFIG_FLAGS= --debug'
18:08:19 + CONFIG_FLAGS=' --debug'
18:08:19 + NODE_TEST_DIR=/home/iojs/node-tmp
18:08:19 + FLAKY_TESTS=dontcare
18:08:19 + make run-ci -j 16
18:08:19 python3 ./configure --verbose  --debug
18:08:21 Node.js configure: Found Python 3.8.10...
18:08:21 Detected C++ compiler (CXX=ccache g++) version: 9.4.0
18:08:21 WARNING: C++ compiler (CXX=ccache g++, 9.4.0) too old, need g++ 10.1.0 or clang++ 8.0.0
18:08:21 Detected C compiler (CC=ccache gcc) version: 9.4.0

@richardlau
Copy link
Member

@targos ah from https://ci.nodejs.org/job/node-test-commit-arm-debug/9398/nodes=ubuntu2004_debug-arm64/injectedEnvVars/ the value of nodes is ubuntu2004_debug-arm64 which isn't matching

*ubuntu2004_sharedlibs* )

I guess we've actually run into #3485 (comment) 🙂.

@richardlau
Copy link
Member

Update to the compiler selector script: #3493

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

Successfully merging this pull request may close these issues.

3 participants