Yum

如何在 CentOS 8 上安裝 Node.js 12?

  • April 2, 2020

我嘗試了以下這篇文章,其中指出

應用程序流通常以包含的軟體版本命名,例如 nodejs:8 或 nodejs:10

$$ … $$

…但正如您在下面看到的:它不起作用。

$ dnf module list nodejs
   Last metadata expiration check: 0:01:21 ago on Thu 02 Apr 2020 09:23:13 PM CEST.
   CentOS-8 - AppStream
   Name               Stream             Profiles                                          Summary
   nodejs             10 [d]             common [d], development, minimal, s2i             Javascript runtime
   nodejs             12                 common, development, minimal, s2i                 Javascript runtime
   Hint: [d]efault, [e]nabled, [x]disabled, [i]nstalled

$ sudo dnf module install nodejs:12
   Last metadata expiration check: 0:51:35 ago on Thu 02 Apr 2020 08:33:41 PM CEST.
   Error: Problems in request:
   missing groups or modules: nodejs:12

如何指定我想要的應用程序流又名版本?

yum module enable nodejs:12
yum install @nodejs:12/common

取自這裡:https ://docs.centos.org/en-US/8-docs/managing-userspace-components/assembly_installing-rhel-8-content/

引用自:https://serverfault.com/questions/1010642