J’étais resté bloqué sur le fait que j’étais bien sur la dernière version existante !
mon anglais n’est pas toujours très bon, j’utilise beaucoup le traducteur.
Et « already the newest version » = « déjà la dernière version » dans google ^^
Je t’autorise !
Je vais creuser dans ce sens. Je viendrais donner le résultat ici (pour les autres).
Merci pour tout.
## Installing the NodeSource Node.js 12.x repo...
## Populating apt-get cache...
+ apt-get update
Ign:1 http://download.videolan.org/pub/debian/stable InRelease
Hit:2 http://download.videolan.org/pub/debian/stable Release
Ign:3 http://deb.debian.org/debian stretch InRelease
Hit:4 http://deb.debian.org/debian-security stretch/updates InRelease
Get:5 http://deb.debian.org/debian stretch-updates InRelease [91.0 kB]
Hit:6 https://deb.nodesource.com/node_8.x stretch InRelease
Hit:8 http://deb.debian.org/debian stretch Release
Fetched 91.0 kB in 0s (132 kB/s)
Reading package lists...
## Confirming "stretch" is supported...
+ curl -sLf -o /dev/null 'https://deb.nodesource.com/node_12.x/dists/stretch/Release'
## Adding the NodeSource signing key to your keyring...
+ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add -
Warning: apt-key output should not be parsed (stdout is not a terminal)
OK
## Creating apt sources list file for the NodeSource Node.js 12.x repo...
+ echo 'deb https://deb.nodesource.com/node_12.x stretch main' > /etc/apt/sources.list.d/nodesource.list
+ echo 'deb-src https://deb.nodesource.com/node_12.x stretch main' >> /etc/apt/sources.list.d/nodesource.list
## Running `apt-get update` for you...
+ apt-get update
Ign:1 http://download.videolan.org/pub/debian/stable InRelease
Hit:2 http://download.videolan.org/pub/debian/stable Release
Ign:3 http://deb.debian.org/debian stretch InRelease
Hit:4 http://deb.debian.org/debian-security stretch/updates InRelease
Hit:5 http://deb.debian.org/debian stretch-updates InRelease
Hit:6 http://deb.debian.org/debian stretch Release
Get:8 https://deb.nodesource.com/node_12.x stretch InRelease [4585 B]
Fetched 4585 B in 0s (7080 B/s)
Reading package lists...
## Run `sudo apt-get install -y nodejs` to install Node.js 12.x and npm
## You may also need development tools to build native addons:
sudo apt-get install gcc g++ make
## To install the Yarn package manager, run:
curl -sL https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update && sudo apt-get install yarn
Reading package lists...
Building dependency tree...
Reading state information...
nodejs is already the newest version (8.17.0-1nodesource1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Edit : Mais Bruce m’avait déjà fait faire plusieurs manip du style. Cf plus haut dans le topic.
Edit2 : Ah non, du coup je suis peut-être en 8 maintenant ?
1 - création du fichier nodesource.list => il existe déjà avec les bonnes infos dedans.
!
!
!
2 - apt update :
Ign:1 http://download.videolan.org/pub/debian/stable InRelease
Ign:2 http://deb.debian.org/debian stretch InRelease
Atteint:3 http://download.videolan.org/pub/debian/stable Release
Atteint:4 http://deb.debian.org/debian-security stretch/updates InRelease
Réception de:5 http://deb.debian.org/debian stretch-updates InRelease [91,0 kB]
Atteint:6 https://deb.nodesource.com/node_12.x stretch InRelease
Atteint:7 http://deb.debian.org/debian stretch Release
91,0 ko réceptionnés en 0s (137 ko/s)
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
All packages are up to date.
## Installing the NodeSource Node.js 12.x repo...
## Populating apt-get cache...
+ apt-get update
Lecture des listes de paquets... Fait
W: chmod 0700 of directory /var/lib/apt/lists/partial failed - SetupAPTPartialDirectory (1: Opération non permise)
E: Impossible d'ouvrir le fichier verrou /var/lib/apt/lists/lock - open (13: Permission non accordée)
E: Impossible de verrouiller le répertoire /var/lib/apt/lists/
W: Problème de suppression du lien /var/cache/apt/pkgcache.bin - RemoveCaches (13: Permission non accordée)
W: Problème de suppression du lien /var/cache/apt/srcpkgcache.bin - RemoveCaches(13: Permission non accordée)
Error executing command, exiting
!
!
!
4 - apt install nodejs
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
nodejs is already the newest version (8.17.0-1nodesource1).
0 mis à jour, 0 nouvellement installés, 0 à enlever et 0 non mis à jour.
Edit : pour les pb de permission, j’ai essayé avec un sudo, mais c’est pareil
Bonsoir
j’ai le même soucis je suis sous esxi avec une vm debian 9.
je cherche aussi une solution et pour le moment je ne trouve rien de bien précis pour la résolution.
avez vous d’autres pistes ?
Bonsoir,
Comme expliqué plus haut, j’ai préféré désactiver le plugin que de me prendre + la tête.
Je passe donc maintenant par script pour contrôler mes sonoff.
Honnêtement, je te conseille de chercher dans cette voie.
Peut-être voir à passer sur une version Debian supérieure si tu as du courage…
Même souci pour moi, sauf que je reste bloqué en version 10 de nodejs.
Le lien qu’a donné @Salvialf ne résout pas mon souci.
si je lance sudo curl -sL https: //deb.nodesource.com/setup_12.x | sudo -E bash -
et après sudo apt-get install -y nodejs
Il me réinstalle la v10 et pas la v12.
Mes logs ci-dessous:
Début de l'installation
--2020-02-12 13:14:13-- https://raw.githubusercontent.com/lunarok/jeedom_nodejs/master/nodejs.sh
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 151.101.64.133, 151.101.128.133, 151.101.192.133, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|151.101.64.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1491 (1.5K) [text/plain]
Saving to: 'dependencies.sh'
0K . 100% 1.24M=0.001s
2020-02-12 13:14:13 (1.24 MB/s) - 'dependencies.sh' saved [1491/1491]
dependencies.sh: 3: [: espeasy: unexpected operator
Version actuelle : 10
Hit:1 http://archive.raspberrypi.org/debian buster InRelease
Hit:2 http://security.debian.org buster/updates InRelease
Hit:3 https://dl.yarnpkg.com/debian stable InRelease
Hit:4 http://linux.teamviewer.com/deb stable InRelease
Hit:5 https://deb.nodesource.com/node_12.x buster InRelease
Hit:6 http://ftp.debian.org/debian buster InRelease
Hit:7 http://ftp.debian.org/debian buster-updates InRelease
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
lsb-release is already the newest version (10.2019051400).
0 upgraded, 0 newly installed, 0 to remove and 12 not upgraded.
KO, version obsolète à upgrader
Suppression du Nodejs existant et installation du paquet recommandé
Reading package lists...
Building dependency tree...
Reading state information...
Package 'npm' is not installed, so not removed
The following packages will be REMOVED:
nodejs*
0 upgraded, 0 newly installed, 1 to remove and 12 not upgraded.
After this operation, 160 kB disk space will be freed.
(Reading database ...
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 172155 files and directories currently installed.)
Removing nodejs (10.15.2~dfsg-2) ...
Processing triggers for man-db (2.8.5-2) ...
dependencies.sh: 37: [: x86_64: unexpected operator
Utilisation du dépot officiel
## Installing the NodeSource Node.js 12.x repo...
## Populating apt-get cache...
+ apt-get update
Hit:1 http://security.debian.org buster/updates InRelease
Hit:2 http://archive.raspberrypi.org/debian buster InRelease
Hit:3 http://linux.teamviewer.com/deb stable InRelease
Hit:4 http://ftp.debian.org/debian buster InRelease
Hit:5 http://ftp.debian.org/debian buster-updates InRelease
Hit:6 https://dl.yarnpkg.com/debian stable InRelease
Hit:7 https://deb.nodesource.com/node_12.x buster InRelease
Reading package lists...
## Confirming "buster" is supported...
+ curl -sLf -o /dev/null 'https://deb.nodesource.com/node_12.x/dists/buster/Release'
## Adding the NodeSource signing key to your keyring...
+ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add -
Warning: apt-key output should not be parsed (stdout is not a terminal)
OK
## Creating apt sources list file for the NodeSource Node.js 12.x repo...
+ echo 'deb https://deb.nodesource.com/node_12.x buster main' > /etc/apt/sources.list.d/nodesource.list
+ echo 'deb-src https://deb.nodesource.com/node_12.x buster main' >> /etc/apt/sources.list.d/nodesource.list
## Running `apt-get update` for you...
+ apt-get update
Hit:1 http://security.debian.org buster/updates InRelease
Hit:2 http://ftp.debian.org/debian buster InRelease
Hit:3 http://archive.raspberrypi.org/debian buster InRelease
Hit:4 http://linux.teamviewer.com/deb stable InRelease
Hit:5 http://ftp.debian.org/debian buster-updates InRelease
Hit:6 https://deb.nodesource.com/node_12.x buster InRelease
Hit:7 https://dl.yarnpkg.com/debian stable InRelease
Reading package lists...
## Run `sudo apt-get install -y nodejs` to install Node.js 12.x and npm
## You may also need development tools to build native addons:
sudo apt-get install gcc g++ make
## To install the Yarn package manager, run:
curl -sL https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update && sudo apt-get install yarn
Reading package lists...
Building dependency tree...
Reading state information...
Suggested packages:
npm
The following NEW packages will be installed:
nodejs
debconf: unable to initialize frontend: Dialog
debconf: (Dialog frontend will not work on a dumb terminal, an emacs shell buffer, or without a controlling terminal.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (This frontend requires a controlling tty.)
debconf: falling back to frontend: Teletype
dpkg-preconfigure: unable to re-open stdin:
0 upgraded, 1 newly installed, 0 to remove and 12 not upgraded.
Need to get 0 B/86.3 kB of archives.
After this operation, 160 kB of additional disk space will be used.
Selecting previously unselected package nodejs.
(Reading database ...
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 172144 files and directories currently installed.)
Preparing to unpack .../nodejs_10.15.2~dfsg-2_i386.deb ...
Unpacking nodejs (10.15.2~dfsg-2) ...
Setting up nodejs (10.15.2~dfsg-2) ...
update-alternatives: using /usr/bin/nodejs to provide /usr/bin/js (js) in auto mode
Processing triggers for man-db (2.8.5-2) ...
Version actuelle : v10.15.2
dependencies.sh: 59: dependencies.sh: npm: not found
chown: cannot access 'node_modules': No such file or directory
Fin de l'installation
Votre aide me serait précieuse et je vous en remercie
Non, c’est vrai que c’est un élément que je n’ai pas vraiment cherché.
Je passe par un virtuel pour ça, mais c’est pas vraiment l’état du connecteur. Juste une représentation virtuelle.
Je suis sûr que c’est un truc qui est récupérable. Je vais chercher…
Bon j’ai trouvé.
ça va être long à exécuter et des choses seront inutiles dans ce que ça fait mais ça a fini par installer correctement les dépendances.
Installe nodejs v12 en le compilant:
1.Créer un dossier TEMP: « mkdir temp » puis rentre dans le dossier « cd temp »
2. Telecharge le package: « wget https://nodejs.org/dist/v12.16.0/node-v12.16.0.tar.gz »
3. unpack: « tar xvzf node-v12.16.0.tar.gz.tar.gz »
4 « ./configure »
5. « make »
6. « sudo make install »
Retourne installer les dépendances et la bingo, ça a marché pour moi.