department-of-veterans-affairs / va.gov-cms

Editor-centered management for Veteran-centered content.
https://prod.cms.va.gov
GNU General Public License v2.0
99 stars 68 forks source link

Amazon Linux 2 and NodeJS 18 #17403

Open edmund-dunn opened 8 months ago

edmund-dunn commented 8 months ago

User Story or Problem Statement

We need to update the version of amazon linux we are using to a newer version.

Description or Additional Context

We received an error after merging a PR for AP that ended in an error.

sh-4.2$ sudo su
[root@ip-172-31-16-9 bin]# uname -a
Linux ip-172-31-16-9.us-gov-west-1.compute.internal 5.10.118-111.515.amzn2.x86_64 #1 SMP Wed May 25 22:12:19 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
[root@ip-172-31-16-9 bin]# sudo - su
sudo: -: command not found
[root@ip-172-31-16-9 bin]# su - cms
-bash: /etc/sysconfig/httpd: No such file or directory
[cms@ip-172-31-16-9 cms]$ composer va:next:install
> # Prepare the next build project
> ! ./scripts/should-run-directly.sh || ./scripts/next-install.sh
Repo next-build already cloned.
v18.17.0 is already installed.
Now using node v18.17.0 (npm v)
Now using node v18.17.0 (npm v)
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
Node
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
NPM
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
Yarn
node: /lib64/libm.so.6: version `GLIBC_2.27' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by node)
Script ! ./scripts/should-run-directly.sh || ./scripts/next-install.sh handling the va:next:install event returned with error code 1
[cms@ip-172-31-16-9 cms]$

After discussing with @tjheffner e found that according to this https://stackoverflow.com/questions/72022527/glibc-2-27-not-found-while-installing-node-on-amazon-ec2-instance we need to update to a newer version of amazon linux.

Steps for Implementation

Acceptance Criteria

Team

Please check the team(s) that will do this work.

gracekretschmer-metrostar commented 2 weeks ago

This work is blocked until platform upgrades NodeJS 18.