Hébergement Cloud Web - Install nodejs avec Moteur d'exécution Ruby 2.5
... / Install nodejs avec Moteu...
BMPCreated with Sketch.BMPZIPCreated with Sketch.ZIPXLSCreated with Sketch.XLSTXTCreated with Sketch.TXTPPTCreated with Sketch.PPTPNGCreated with Sketch.PNGPDFCreated with Sketch.PDFJPGCreated with Sketch.JPGGIFCreated with Sketch.GIFDOCCreated with Sketch.DOC Error Created with Sketch.
Frage

Install nodejs avec Moteur d'exécution Ruby 2.5

Von
SISCUS
Erstellungsdatum 2021-07-04 11:03:12 (edited on 2024-09-04 14:05:00) in Hébergement Cloud Web

Salutations,
je souhaite mettre en place une appli écrite en ruby
l'offre souscrite est Cloud Web 1,
git : 2.11.0
rbenv : 1.1.2-61-g585ed84
ruby : 2.5.5p157 (2019-03-15 revision 67260) [x86_64-linux]
rails : 6.1.4
gem : 2.7.6.2
Bundler : 2.2.21

en créant la nouvelle (et première) application Rails avec $rails new ao
j'obtiens ce message :
sh: 1: node: not found
sh: 1: nodejs: not found
Node.js not installed. Please download and install Node.js https://nodejs.org/en/download/
Exiting!

alors que un ls -hla /usr/local/
liste bien nodejs10 11 12 et 14 (celle dont j'ai besoin)

j'ai essayé 2 méthodes :
la première
$ sed -i 's@\["nodejs", "node"\],@["/usr/local/nodejs14/bin/node"],@' ${GEM_HOME}/gems/execjs-2.7.0/lib/execjs/runtimes.rb
sed: can't read /home/alphaok/.gem/ruby/2.5.0/gems/execjs-2.7.0/lib/execjs/runtimes.rb: No such file or directory

il n'y a effectivement aucun execjs

et la seconde n'est pas autorisée :

$ curl -fsSL https://deb.nodesource.com/setup_14.x | bash -
## Installing the NodeSource Node.js 14.x repo...

## Populating apt-get cache...
+ apt-get update
Reading package lists... Done
E: List directory /var/lib/apt/lists/partial is missing. - Acquire (13: Permission denied)
Error executing command, exiting

Avez vous déjà rencontré ce souci et comment y remédier ?

dans l'attente,
cordialement