I had problems installing node.js using the official install script. The problem
is that the update step fails. There is no clue in the install log file as far as I can see.
To solve the problem I installed node/nmp following the excellent guide here
After you gone throw the steps in the guide just run the install script again and everything will be alright. At least it was for me on a machine running Debian Stretch and some other boxes.