Steam Deck

Steam Deck

Tellic Nov 13, 2023 @ 9:33am
NodeJS
So, yeah, I guess I want my Steam Deck to be able to do everything, but I thought I'd have a go at a bit of Javascript development on it.

Problem is ... I just can't get Node/NPM working on it, no matter what I try.

Any and all help would be appreciated. TLDR; skip to the "Running npm" bit unless you think my install method is the culprit!

Installing
Even installing seemed problematic.

Through 'Discover' I could see versions 18 and 16, but after installing and creating some symlinks - it would report that crtyptolib.so.3 was not installled. (Which it is, as it's part of the latest OpenSSL which I do have installed)

Outside of discover, using 'pacman', just keep getting errors about coders being disabled/packages corrupted.

Similar results using flatpak - which just wouldn't complete.

I think a 'yay' install kind of worked, but then npm and node commands would just hang - see later...

Finally, I just installed 'nvm' and easily, and quickly installed node and npm at latest recommended versions - Woot!

Running npm
Sadly...

... even after installing what appear to be working versions of node and npm, they just don't really work. They kind of work, sometimes...

For example - 'node -v' and 'npm -v' correctly report their versions.

But if I try to do any kind of 'npm install' command, it just always hangs.

I've tried configuring ipv6 to local link only, and disabling it
I've tried using VPN
I've tried ehternet cable Vs. WiFi Vs. mobile phone hotspot 5G
I've tried yarn instead of npm - and that hangs too (seemingly - one more attempt to go on that one)
I've tried verbose install mode
I've tried setting strict-ssl and progress to false for the npm config

Perhaps the weirdest behaviour, is that even commands like 'npm cache clear --force' can work sometimes, and then just completely hang at other times which is baffling.

If it was not compiled to work with the OS, surely it would never work...
Why would a clear cache command work sometimes, and not others?
Why would config changes work sometimes, and not others?

Is the Nvme hard disk too quick? Or is it failing? I have 56Gb left free. Permissions? Not sure permissions would allow install of a handful of packages before hanging randomly on others...

I'm on the verge of giving up ... unless some genius out there has any ideas?
< >
Showing 1-12 of 12 comments
deaddoof Nov 13, 2023 @ 9:42am 
Install distrobox. Run ubuntu in distrobox and install any application you need. I believe there are steam deck specific instructions.
WarnerCK Nov 13, 2023 @ 9:59am 
There's a guide here.[github.com]
Tellic Nov 13, 2023 @ 10:05am 
@deaddoof & @WarnerCK Thanks - I will give that a try.

I appreciate it: :steamthumbsup:
Tellic Nov 14, 2023 @ 8:59am 
Sadly, I have Ubuntu running through DistroBox on my Steam Deck...

...and I am still unable to get Node and NPM commands to run to completion. They get so far, and then just hang.
Even Yarn falls over.
Even using a VPN over a mobile hotspot to avoid my fibre connection.
Even with the Node and NPM installed inside the Ubuntu distro...

I don't think I have done anything weird with proxies...

If there's any genius out there who might understand why NPM commands start and then *ALWAYS* stall out after a few seconds....

:steamsad:
Last edited by Tellic; Nov 14, 2023 @ 8:59am
deaddoof Nov 14, 2023 @ 9:19am 
npm config list
Tellic Nov 14, 2023 @ 9:49am 
Originally posted by deaddoof:
npm config list

npm info using npm@10.1.0 npm info using node@v20.9.0 ; "user" config from /home/deck/.npmrc /registry.npmjs.org/:_authToken = (protected) always-auth = true email = "xxxxxxxx@xxxxxxxx.co.uk" loglevel = "info" strict-ssl = false ; node bin location = /home/deck/.nvm/versions/node/v20.9.0/bin/node ; node version = v20.9.0 ; npm local prefix = /home/deck/ubu/prod/l/cattle-rustler ; npm version = 10.1.0 ; cwd = /home/deck/ubu/prod/l/cattle-rustler ; HOME = /home/deck ; Run `npm config ls -l` to show all defaults. npm info ok

I have tried logging in with npm login credentials for the latest attempts and added always-auth=true. I disabled strict-ssl some time ago just in case...

Node/NPM is installed via NVM here - but I was having similar problems with different installs. The main suggested solution to hanging installs was to restrict IPV6 to Local links only, but that has not helped, and I'm not sure that would explain why a cache clear command would work sometimes and not others.
Last edited by Tellic; Nov 14, 2023 @ 9:51am
deaddoof Nov 14, 2023 @ 10:11am 
Originally posted by Tellic:
Originally posted by deaddoof:
npm config list

npm info using npm@10.1.0 npm info using node@v20.9.0 ; "user" config from /home/deck/.npmrc /registry.npmjs.org/:_authToken = (protected) always-auth = true email = "xxxxxxxx@xxxxxxxx.co.uk" loglevel = "info" strict-ssl = false ; node bin location = /home/deck/.nvm/versions/node/v20.9.0/bin/node ; node version = v20.9.0 ; npm local prefix = /home/deck/ubu/prod/l/cattle-rustler ; npm version = 10.1.0 ; cwd = /home/deck/ubu/prod/l/cattle-rustler ; HOME = /home/deck ; Run `npm config ls -l` to show all defaults. npm info ok

I have tried logging in with npm login credentials for the latest attempts and added always-auth=true. I disabled strict-ssl some time ago just in case...

Node/NPM is installed via NVM here - but I was having similar problems with different installs. The main suggested solution to hanging installs was to restrict IPV6 to Local links only, but that has not helped, and I'm not sure that would explain why a cache clear command would work sometimes and not others.

https://packages.ubuntu.com/search?keywords=nodejs

Why is it v20? Are you sure you are using ubuntu nodejs packages?

Distrobox should be completely isolated from the rest of the system.
Tellic Nov 14, 2023 @ 10:22am 

.....

https://packages.ubuntu.com/search?keywords=nodejs

Why is it v20? Are you sure you are using ubuntu nodejs packages?

Distrobox should be completely isolated from the rest of the system.

So, I think installing via the curl nvm install command, breaks out of the distro somehow (or I failed to clean it up properly...)

Anyway - I uninstalled all the npm / node / nvm stuff.

'Enter'ed the ubuntu distro.

Installed via `apt update` / `apt install nodejs npm`

And voila - at last - a working version.

Node is back at v12.22.9 !!!, and npm at 8.5.1 - but at least they got my old bulls and cows game running.

Thanks for all the help. :steamthumbsup:

Now ... how are my npx create react app commands going to turn out... :steamhappy:
deaddoof Nov 14, 2023 @ 11:01am 
Originally posted by Tellic:

.....

https://packages.ubuntu.com/search?keywords=nodejs

Why is it v20? Are you sure you are using ubuntu nodejs packages?

Distrobox should be completely isolated from the rest of the system.

So, I think installing via the curl nvm install command, breaks out of the distro somehow (or I failed to clean it up properly...)

Anyway - I uninstalled all the npm / node / nvm stuff.

'Enter'ed the ubuntu distro.

Installed via `apt update` / `apt install nodejs npm`

And voila - at last - a working version.

Node is back at v12.22.9 !!!, and npm at 8.5.1 - but at least they got my old bulls and cows game running.

Thanks for all the help. :steamthumbsup:

Now ... how are my npx create react app commands going to turn out... :steamhappy:

I highly recommend you treat your software like how enterprise user does it for immutable software. Use a stable distro with releases measure in years. You will spend lots of time configuring anyways. This stability allows your experience to be relevant for at least 2 years.
Tellic Nov 15, 2023 @ 4:25am 
Just a general FYI of my ongoing exploration.

OK, so NodeJS 12 is just way too old - it was way too old last time I was using NodeJS a year ago :steamhappy:
[create-react-app is an 'old' way to create react apps, and it needs v14 at least! (Goodness knows what vite or next.js would think about an attempt to use v12]

Anyway, there may be better linux distros, or better ubuntu distros that I might explore, but with ubuntu:22.04 you are a bit limited.

As mentioned in previous posts v20+ just doesn't work, but v18.18.2 LTS seems to be running in a pretty stable way (even though it isn't officially supported) so fingers crossed and now I can have a more serious play around :steamhappy:
Last edited by Tellic; Nov 15, 2023 @ 4:27am
deaddoof Nov 15, 2023 @ 4:35am 
Originally posted by Tellic:
Just a general FYI of my ongoing exploration.

OK, so NodeJS 12 is just way too old - it was way too old last time I was using NodeJS a year ago :steamhappy:
[create-react-app is an 'old' way to create react apps, and it needs v14 at least! (Goodness knows what vite or next.js would think about an attempt to use v12]

Anyway, there may be better linux distros, or better ubuntu distros that I might explore, but with ubuntu:22.04 you are a bit limited.

As mentioned in previous posts v20+ just doesn't work, but v18.18.2 LTS seems to be running in a pretty stable way (even though it isn't officially supported) so fingers crossed and now I can have a more serious play around :steamhappy:


Just install it in the distrobox. You can throw out the container if you mess up.
Tellic Jan 10, 2024 @ 11:39am 
Originally posted by deaddoof:
Originally posted by Tellic:
Just a general FYI of my ongoing exploration.

OK, so NodeJS 12 is just way too old - it was way too old last time I was using NodeJS a year ago :steamhappy:
[create-react-app is an 'old' way to create react apps, and it needs v14 at least! (Goodness knows what vite or next.js would think about an attempt to use v12]

Anyway, there may be better linux distros, or better ubuntu distros that I might explore, but with ubuntu:22.04 you are a bit limited.

As mentioned in previous posts v20+ just doesn't work, but v18.18.2 LTS seems to be running in a pretty stable way (even though it isn't officially supported) so fingers crossed and now I can have a more serious play around :steamhappy:


Just install it in the distrobox. You can throw out the container if you mess up.

I'm talking about distrobox in my post here.

As I also mentioned, there may be better distros (Ubuntu or otherwise) to use inside distrobox, so if anyone knows a distrobox distro that supports the latest Node/npm versions, feel free to post here :steamthumbsup:
< >
Showing 1-12 of 12 comments
Per page: 1530 50

Date Posted: Nov 13, 2023 @ 9:33am
Posts: 12