This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

npm ci command not working. When I'm installing the cat tracker web application

Hey, I'm trying to install the cat tracker application. When I'm executing the npm ci command. It is prompting the following error

ubuntu@ip-172-31-25-55:~/aws/nrf-asset-tracker-firmware-aws/cat-tracker-web-app$ npm ci
npm ERR! fsevents not accessible from jest-haste-map

npm ERR! A complete log of this run can be found in:
npm ERR! /home/ubuntu/.npm/_logs/2021-05-29T15_17_05_201Z-debug.log

Can anyone help me in solving this. 

Parents
  • I can't reproduce this:

    root@42a4b26c6299:/asset-tracker-cloud-app-js# lsb_release -a
    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 18.04.5 LTS
    Release:        18.04
    Codename:       bionic
    root@42a4b26c6299:/asset-tracker-cloud-app-js# node -v
    v14.17.0
    root@42a4b26c6299:/asset-tracker-cloud-app-js# npm -v
    7.15.1
    root@42a4b26c6299:/asset-tracker-cloud-app-js# npm ci
    npm WARN deprecated [email protected]: Deprecated due to CVE-2021-21366 resolved in 0.5.0
    npm WARN deprecated [email protected]: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-babel.
    npm WARN deprecated [email protected]: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
    npm WARN deprecated [email protected]: Please see https://github.com/lydell/urix#deprecated
    npm WARN deprecated [email protected]: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
    npm WARN deprecated [email protected]: https://github.com/lydell/resolve-url#deprecated
    npm WARN deprecated [email protected]: support for ECMAScript is superseded by `uglify-js` as of v3.13.0
    npm WARN deprecated [email protected]: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates.
    npm WARN deprecated [email protected]: You can find the new Popper v2 at @popperjs/core, this package is dedicated to the legacy v1
    npm WARN deprecated @hapi/[email protected]: This version has been deprecated and is no longer supported or maintained
    npm WARN deprecated @hapi/[email protected]: This version has been deprecated and is no longer supported or maintained
    npm WARN deprecated @hapi/[email protected]: Moved to 'npm install @sideway/address'
    npm WARN deprecated @hapi/[email protected]: This version has been deprecated and is no longer supported or maintained
    npm WARN deprecated @hapi/[email protected]: Switch to 'npm install joi'
    npm WARN deprecated [email protected]: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
    
    > @nordicsemiconductor/[email protected] postinstall
    > husky install
    
    husky - Git hooks installed
    
    added 4097 packages, and audited 4098 packages in 45s
    
    177 packages are looking for funding
      run `npm fund` for details
    
    87 vulnerabilities (2 low, 84 moderate, 1 high)
    
    To address issues that do not require attention, run:
      npm audit fix
    
    To address all issues (including breaking changes), run:
      npm audit fix --force
    
    Run `npm audit` for details.
    root@42a4b26c6299:/asset-tracker-cloud-app-js# 
    

    Which version of Node.js and NPM do you have?

  • Markus,

    I was using the node and npm with the following versions on it

    node - v12.22.1

    npm-7.15.1

    Thanks

  • Did you do this in both the web app and the AWS project directory?

  • Yup, As far I remembered. But for now, I ran the command in both the web app and the AWS project directory, It is giving me a message as below

    /usr/local/bin/npx: No such file or directory

    Can you please let me know how to solve it

  • Markus,


    I'm still trying to make it work. Couldn't figure it out. Can you please let me know, How to fix this?

  • After installing Node.js 14 on Ubuntu 18.04, npx is located in /usr/bin/npx.

     docker run -it ubuntu:18.04                                    
    Unable to find image 'ubuntu:18.04' locally
    18.04: Pulling from library/ubuntu
    4bbfd2c87b75: Pull complete 
    d2e110be24e1: Pull complete 
    889a7173dcfe: Pull complete 
    Digest: sha256:67b730ece0d34429b455c08124ffd444f021b81e06fa2d9cd0adaf0d0b875182
    Status: Downloaded newer image for ubuntu:18.04
    root@f0171301951f:/# npx
    bash: npx: command not found
    root@f0171301951f:/# apt-get update
    Get:1 http://archive.ubuntu.com/ubuntu bionic InRelease [242 kB]
    Get:2 http://security.ubuntu.com/ubuntu bionic-security InRelease [88.7 kB]
    Get:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]           
    Get:4 http://archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]                     
    Get:5 http://archive.ubuntu.com/ubuntu bionic/multiverse amd64 Packages [186 kB]              
    Get:6 http://archive.ubuntu.com/ubuntu bionic/restricted amd64 Packages [13.5 kB]
    Get:7 http://archive.ubuntu.com/ubuntu bionic/main amd64 Packages [1344 kB]
    Get:8 http://archive.ubuntu.com/ubuntu bionic/universe amd64 Packages [11.3 MB]    
    Get:9 http://security.ubuntu.com/ubuntu bionic-security/universe amd64 Packages [1414 kB]
    Get:10 http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages [2154 kB]
    Get:11 http://archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages [2184 kB]
    Get:12 http://security.ubuntu.com/ubuntu bionic-security/restricted amd64 Packages [423 kB] 
    Get:13 http://security.ubuntu.com/ubuntu bionic-security/multiverse amd64 Packages [24.7 kB]
    Get:14 http://archive.ubuntu.com/ubuntu bionic-updates/restricted amd64 Packages [452 kB]    
    Get:15 http://archive.ubuntu.com/ubuntu bionic-updates/multiverse amd64 Packages [31.6 kB]
    Get:16 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [2586 kB]
    Get:17 http://archive.ubuntu.com/ubuntu bionic-backports/main amd64 Packages [11.3 kB]
    Get:18 http://archive.ubuntu.com/ubuntu bionic-backports/universe amd64 Packages [11.4 kB]
    Fetched 22.7 MB in 3s (8686 kB/s)                          
    Reading package lists... Done
    root@f0171301951f:/# apt-get install curl
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following additional packages will be installed:
      ca-certificates krb5-locales libasn1-8-heimdal libcurl4 libgssapi-krb5-2 libgssapi3-heimdal libhcrypto4-heimdal libheimbase1-heimdal libheimntlm0-heimdal libhx509-5-heimdal libk5crypto3 libkeyutils1 libkrb5-26-heimdal libkrb5-3
      libkrb5support0 libldap-2.4-2 libldap-common libnghttp2-14 libpsl5 libroken18-heimdal librtmp1 libsasl2-2 libsasl2-modules libsasl2-modules-db libsqlite3-0 libssl1.1 libwind0-heimdal openssl publicsuffix
    Suggested packages:
      krb5-doc krb5-user libsasl2-modules-gssapi-mit | libsasl2-modules-gssapi-heimdal libsasl2-modules-ldap libsasl2-modules-otp libsasl2-modules-sql
    The following NEW packages will be installed:
      ca-certificates curl krb5-locales libasn1-8-heimdal libcurl4 libgssapi-krb5-2 libgssapi3-heimdal libhcrypto4-heimdal libheimbase1-heimdal libheimntlm0-heimdal libhx509-5-heimdal libk5crypto3 libkeyutils1 libkrb5-26-heimdal libkrb5-3
      libkrb5support0 libldap-2.4-2 libldap-common libnghttp2-14 libpsl5 libroken18-heimdal librtmp1 libsasl2-2 libsasl2-modules libsasl2-modules-db libsqlite3-0 libssl1.1 libwind0-heimdal openssl publicsuffix
    0 upgraded, 30 newly installed, 0 to remove and 5 not upgraded.
    Need to get 4835 kB of archives.
    After this operation, 14.8 MB of additional disk space will be used.
    Do you want to continue? [Y/n] 
    Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libssl1.1 amd64 1.1.1-1ubuntu2.1~18.04.9 [1301 kB]
    Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 openssl amd64 1.1.1-1ubuntu2.1~18.04.9 [614 kB]
    Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 ca-certificates all 20210119~18.04.1 [147 kB]
    Get:4 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libsqlite3-0 amd64 3.22.0-1ubuntu0.4 [499 kB]
    Get:5 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 krb5-locales all 1.16-2ubuntu0.2 [13.4 kB]
    Get:6 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libkrb5support0 amd64 1.16-2ubuntu0.2 [30.8 kB]
    Get:7 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libk5crypto3 amd64 1.16-2ubuntu0.2 [85.5 kB]
    Get:8 http://archive.ubuntu.com/ubuntu bionic/main amd64 libkeyutils1 amd64 1.5.9-9.2ubuntu2 [8720 B]
    Get:9 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libkrb5-3 amd64 1.16-2ubuntu0.2 [279 kB]
    Get:10 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libgssapi-krb5-2 amd64 1.16-2ubuntu0.2 [122 kB]
    Get:11 http://archive.ubuntu.com/ubuntu bionic/main amd64 libpsl5 amd64 0.19.1-5build1 [41.8 kB]
    Get:12 http://archive.ubuntu.com/ubuntu bionic/main amd64 publicsuffix all 20180223.1310-1 [97.6 kB]
    Get:13 http://archive.ubuntu.com/ubuntu bionic/main amd64 libroken18-heimdal amd64 7.5.0+dfsg-1 [41.3 kB]
    Get:14 http://archive.ubuntu.com/ubuntu bionic/main amd64 libasn1-8-heimdal amd64 7.5.0+dfsg-1 [175 kB]
    Get:15 http://archive.ubuntu.com/ubuntu bionic/main amd64 libheimbase1-heimdal amd64 7.5.0+dfsg-1 [29.3 kB]
    Get:16 http://archive.ubuntu.com/ubuntu bionic/main amd64 libhcrypto4-heimdal amd64 7.5.0+dfsg-1 [85.9 kB]
    Get:17 http://archive.ubuntu.com/ubuntu bionic/main amd64 libwind0-heimdal amd64 7.5.0+dfsg-1 [47.8 kB]
    Get:18 http://archive.ubuntu.com/ubuntu bionic/main amd64 libhx509-5-heimdal amd64 7.5.0+dfsg-1 [107 kB]
    Get:19 http://archive.ubuntu.com/ubuntu bionic/main amd64 libkrb5-26-heimdal amd64 7.5.0+dfsg-1 [206 kB]
    Get:20 http://archive.ubuntu.com/ubuntu bionic/main amd64 libheimntlm0-heimdal amd64 7.5.0+dfsg-1 [14.8 kB]
    Get:21 http://archive.ubuntu.com/ubuntu bionic/main amd64 libgssapi3-heimdal amd64 7.5.0+dfsg-1 [96.5 kB]
    Get:22 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libsasl2-modules-db amd64 2.1.27~101-g0780600+dfsg-3ubuntu2.3 [15.0 kB]
    Get:23 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libsasl2-2 amd64 2.1.27~101-g0780600+dfsg-3ubuntu2.3 [49.2 kB]
    Get:24 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libldap-common all 2.4.45+dfsg-1ubuntu1.10 [15.8 kB]
    Get:25 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libldap-2.4-2 amd64 2.4.45+dfsg-1ubuntu1.10 [154 kB]
    Get:26 http://archive.ubuntu.com/ubuntu bionic/main amd64 libnghttp2-14 amd64 1.30.0-1ubuntu1 [77.8 kB]
    Get:27 http://archive.ubuntu.com/ubuntu bionic/main amd64 librtmp1 amd64 2.4+20151223.gitfa8646d.1-1 [54.2 kB]
    Get:28 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libcurl4 amd64 7.58.0-2ubuntu3.13 [219 kB]
    Get:29 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 curl amd64 7.58.0-2ubuntu3.13 [159 kB]
    Get:30 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libsasl2-modules amd64 2.1.27~101-g0780600+dfsg-3ubuntu2.3 [48.9 kB]
    Fetched 4835 kB in 1s (7569 kB/s)             
    debconf: delaying package configuration, since apt-utils is not installed
    Selecting previously unselected package libssl1.1:amd64.
    (Reading database ... 4045 files and directories currently installed.)
    Preparing to unpack .../00-libssl1.1_1.1.1-1ubuntu2.1~18.04.9_amd64.deb ...
    Unpacking libssl1.1:amd64 (1.1.1-1ubuntu2.1~18.04.9) ...
    Selecting previously unselected package openssl.
    Preparing to unpack .../01-openssl_1.1.1-1ubuntu2.1~18.04.9_amd64.deb ...
    Unpacking openssl (1.1.1-1ubuntu2.1~18.04.9) ...
    Selecting previously unselected package ca-certificates.
    Preparing to unpack .../02-ca-certificates_20210119~18.04.1_all.deb ...
    Unpacking ca-certificates (20210119~18.04.1) ...
    Selecting previously unselected package libsqlite3-0:amd64.
    Preparing to unpack .../03-libsqlite3-0_3.22.0-1ubuntu0.4_amd64.deb ...
    Unpacking libsqlite3-0:amd64 (3.22.0-1ubuntu0.4) ...
    Selecting previously unselected package krb5-locales.
    Preparing to unpack .../04-krb5-locales_1.16-2ubuntu0.2_all.deb ...
    Unpacking krb5-locales (1.16-2ubuntu0.2) ...
    Selecting previously unselected package libkrb5support0:amd64.
    Preparing to unpack .../05-libkrb5support0_1.16-2ubuntu0.2_amd64.deb ...
    Unpacking libkrb5support0:amd64 (1.16-2ubuntu0.2) ...
    Selecting previously unselected package libk5crypto3:amd64.
    Preparing to unpack .../06-libk5crypto3_1.16-2ubuntu0.2_amd64.deb ...
    Unpacking libk5crypto3:amd64 (1.16-2ubuntu0.2) ...
    Selecting previously unselected package libkeyutils1:amd64.
    Preparing to unpack .../07-libkeyutils1_1.5.9-9.2ubuntu2_amd64.deb ...
    Unpacking libkeyutils1:amd64 (1.5.9-9.2ubuntu2) ...
    Selecting previously unselected package libkrb5-3:amd64.
    Preparing to unpack .../08-libkrb5-3_1.16-2ubuntu0.2_amd64.deb ...
    Unpacking libkrb5-3:amd64 (1.16-2ubuntu0.2) ...
    Selecting previously unselected package libgssapi-krb5-2:amd64.
    Preparing to unpack .../09-libgssapi-krb5-2_1.16-2ubuntu0.2_amd64.deb ...
    Unpacking libgssapi-krb5-2:amd64 (1.16-2ubuntu0.2) ...
    Selecting previously unselected package libpsl5:amd64.
    Preparing to unpack .../10-libpsl5_0.19.1-5build1_amd64.deb ...
    Unpacking libpsl5:amd64 (0.19.1-5build1) ...
    Selecting previously unselected package publicsuffix.
    Preparing to unpack .../11-publicsuffix_20180223.1310-1_all.deb ...
    Unpacking publicsuffix (20180223.1310-1) ...
    Selecting previously unselected package libroken18-heimdal:amd64.
    Preparing to unpack .../12-libroken18-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libroken18-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libasn1-8-heimdal:amd64.
    Preparing to unpack .../13-libasn1-8-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libasn1-8-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libheimbase1-heimdal:amd64.
    Preparing to unpack .../14-libheimbase1-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libheimbase1-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libhcrypto4-heimdal:amd64.
    Preparing to unpack .../15-libhcrypto4-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libhcrypto4-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libwind0-heimdal:amd64.
    Preparing to unpack .../16-libwind0-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libwind0-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libhx509-5-heimdal:amd64.
    Preparing to unpack .../17-libhx509-5-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libhx509-5-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libkrb5-26-heimdal:amd64.
    Preparing to unpack .../18-libkrb5-26-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libkrb5-26-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libheimntlm0-heimdal:amd64.
    Preparing to unpack .../19-libheimntlm0-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libheimntlm0-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libgssapi3-heimdal:amd64.
    Preparing to unpack .../20-libgssapi3-heimdal_7.5.0+dfsg-1_amd64.deb ...
    Unpacking libgssapi3-heimdal:amd64 (7.5.0+dfsg-1) ...
    Selecting previously unselected package libsasl2-modules-db:amd64.
    Preparing to unpack .../21-libsasl2-modules-db_2.1.27~101-g0780600+dfsg-3ubuntu2.3_amd64.deb ...
    Unpacking libsasl2-modules-db:amd64 (2.1.27~101-g0780600+dfsg-3ubuntu2.3) ...
    Selecting previously unselected package libsasl2-2:amd64.
    Preparing to unpack .../22-libsasl2-2_2.1.27~101-g0780600+dfsg-3ubuntu2.3_amd64.deb ...
    Unpacking libsasl2-2:amd64 (2.1.27~101-g0780600+dfsg-3ubuntu2.3) ...
    Selecting previously unselected package libldap-common.
    Preparing to unpack .../23-libldap-common_2.4.45+dfsg-1ubuntu1.10_all.deb ...
    Unpacking libldap-common (2.4.45+dfsg-1ubuntu1.10) ...
    Selecting previously unselected package libldap-2.4-2:amd64.
    Preparing to unpack .../24-libldap-2.4-2_2.4.45+dfsg-1ubuntu1.10_amd64.deb ...
    Unpacking libldap-2.4-2:amd64 (2.4.45+dfsg-1ubuntu1.10) ...
    Selecting previously unselected package libnghttp2-14:amd64.
    Preparing to unpack .../25-libnghttp2-14_1.30.0-1ubuntu1_amd64.deb ...
    Unpacking libnghttp2-14:amd64 (1.30.0-1ubuntu1) ...
    Selecting previously unselected package librtmp1:amd64.
    Preparing to unpack .../26-librtmp1_2.4+20151223.gitfa8646d.1-1_amd64.deb ...
    Unpacking librtmp1:amd64 (2.4+20151223.gitfa8646d.1-1) ...
    Selecting previously unselected package libcurl4:amd64.
    Preparing to unpack .../27-libcurl4_7.58.0-2ubuntu3.13_amd64.deb ...
    Unpacking libcurl4:amd64 (7.58.0-2ubuntu3.13) ...
    Selecting previously unselected package curl.
    Preparing to unpack .../28-curl_7.58.0-2ubuntu3.13_amd64.deb ...
    Unpacking curl (7.58.0-2ubuntu3.13) ...
    Selecting previously unselected package libsasl2-modules:amd64.
    Preparing to unpack .../29-libsasl2-modules_2.1.27~101-g0780600+dfsg-3ubuntu2.3_amd64.deb ...
    Unpacking libsasl2-modules:amd64 (2.1.27~101-g0780600+dfsg-3ubuntu2.3) ...
    Setting up libnghttp2-14:amd64 (1.30.0-1ubuntu1) ...
    Setting up libldap-common (2.4.45+dfsg-1ubuntu1.10) ...
    Setting up libpsl5:amd64 (0.19.1-5build1) ...
    Setting up libsasl2-modules-db:amd64 (2.1.27~101-g0780600+dfsg-3ubuntu2.3) ...
    Setting up libsasl2-2:amd64 (2.1.27~101-g0780600+dfsg-3ubuntu2.3) ...
    Setting up libroken18-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up librtmp1:amd64 (2.4+20151223.gitfa8646d.1-1) ...
    Setting up libkrb5support0:amd64 (1.16-2ubuntu0.2) ...
    Setting up krb5-locales (1.16-2ubuntu0.2) ...
    Setting up publicsuffix (20180223.1310-1) ...
    Setting up libssl1.1:amd64 (1.1.1-1ubuntu2.1~18.04.9) ...
    debconf: unable to initialize frontend: Dialog
    debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
    debconf: falling back to frontend: Readline
    debconf: unable to initialize frontend: Readline
    debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
    debconf: falling back to frontend: Teletype
    Setting up libheimbase1-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up openssl (1.1.1-1ubuntu2.1~18.04.9) ...
    Setting up libsqlite3-0:amd64 (3.22.0-1ubuntu0.4) ...
    Setting up libkeyutils1:amd64 (1.5.9-9.2ubuntu2) ...
    Setting up libsasl2-modules:amd64 (2.1.27~101-g0780600+dfsg-3ubuntu2.3) ...
    Setting up ca-certificates (20210119~18.04.1) ...
    debconf: unable to initialize frontend: Dialog
    debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
    debconf: falling back to frontend: Readline
    debconf: unable to initialize frontend: Readline
    debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
    debconf: falling back to frontend: Teletype
    Updating certificates in /etc/ssl/certs...
    129 added, 0 removed; done.
    Setting up libk5crypto3:amd64 (1.16-2ubuntu0.2) ...
    Setting up libwind0-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libasn1-8-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libhcrypto4-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libhx509-5-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libkrb5-3:amd64 (1.16-2ubuntu0.2) ...
    Setting up libkrb5-26-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libheimntlm0-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libgssapi-krb5-2:amd64 (1.16-2ubuntu0.2) ...
    Setting up libgssapi3-heimdal:amd64 (7.5.0+dfsg-1) ...
    Setting up libldap-2.4-2:amd64 (2.4.45+dfsg-1ubuntu1.10) ...
    Setting up libcurl4:amd64 (7.58.0-2ubuntu3.13) ...
    Setting up curl (7.58.0-2ubuntu3.13) ...
    Processing triggers for libc-bin (2.27-3ubuntu1.4) ...
    Processing triggers for ca-certificates (20210119~18.04.1) ...
    Updating certificates in /etc/ssl/certs...
    0 added, 0 removed; done.
    Running hooks in /etc/ca-certificates/update.d...
    done.
    root@f0171301951f:/# curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
    bash: sudo: command not found
    
    curl: (23) Failed writing body (0 != 7067)
    root@f0171301951f:/# sudo apt-get install -y nodejs
    bash: sudo: command not found
    root@f0171301951f:/# sudo apt-get install -y nodejs;5D^C
    root@f0171301951f:/# curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -              
    
    ## Installing the NodeSource Node.js 14.x repo...
    
    
    ## Populating apt-get cache...
    
    + apt-get update
    Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
    Hit:2 http://archive.ubuntu.com/ubuntu bionic-updates InRelease                                      
    Hit:3 http://archive.ubuntu.com/ubuntu bionic-backports InRelease                                    
    Hit:4 http://security.ubuntu.com/ubuntu bionic-security InRelease
    Reading package lists... Done                     
    
    ## Installing packages required for setup: lsb-release gnupg...
    
    + apt-get install -y lsb-release gnupg > /dev/null 2>&1
    
    ## Confirming "bionic" is supported...
    
    + curl -sLf -o /dev/null 'https://deb.nodesource.com/node_14.x/dists/bionic/Release'
    
    ## Adding the NodeSource signing key to your keyring...
    
    + curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor | tee /usr/share/keyrings/nodesource.gpg >/dev/null
    
    ## Creating apt sources list file for the NodeSource Node.js 14.x repo...
    
    + echo 'deb [signed-by=/usr/share/keyrings/nodesource.gpg] https://deb.nodesource.com/node_14.x bionic main' > /etc/apt/sources.list.d/nodesource.list
    + echo 'deb-src [signed-by=/usr/share/keyrings/nodesource.gpg] https://deb.nodesource.com/node_14.x bionic main' >> /etc/apt/sources.list.d/nodesource.list
    
    ## Running `apt-get update` for you...
    
    + apt-get update
    Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
    Get:2 https://deb.nodesource.com/node_14.x bionic InRelease [4584 B]       
    Hit:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease                                      
    Hit:4 http://archive.ubuntu.com/ubuntu bionic-backports InRelease                                    
    Hit:5 http://security.ubuntu.com/ubuntu bionic-security InRelease
    Get:6 https://deb.nodesource.com/node_14.x bionic/main amd64 Packages [765 B]
    Fetched 5349 B in 1s (4570 B/s)   
    Reading package lists... Done
    
    ## Run `sudo apt-get install -y nodejs` to install Node.js 14.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 | gpg --dearmor | sudo tee /usr/share/keyrings/yarnkey.gpg >/dev/null
         echo "deb [signed-by=/usr/share/keyrings/yarnkey.gpg] 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
    
    
    root@f0171301951f:/# node -v
    bash: node: command not found
    root@f0171301951f:/# apt-get install -y nodejs
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following additional packages will be installed:
      libpython-stdlib libpython2.7-minimal libpython2.7-stdlib python python-minimal python2.7 python2.7-minimal
    Suggested packages:
      python-doc python-tk python2.7-doc binutils binfmt-support
    The following NEW packages will be installed:
      libpython-stdlib libpython2.7-minimal libpython2.7-stdlib nodejs python python-minimal python2.7 python2.7-minimal
    0 upgraded, 8 newly installed, 0 to remove and 5 not upgraded.
    Need to get 28.9 MB of archives.
    After this operation, 137 MB of additional disk space will be used.
    Get:1 https://deb.nodesource.com/node_14.x bionic/main amd64 nodejs amd64 14.17.0-1nodesource1 [24.9 MB]
    Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libpython2.7-minimal amd64 2.7.17-1~18.04ubuntu1.6 [335 kB]
    Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 python2.7-minimal amd64 2.7.17-1~18.04ubuntu1.6 [1291 kB]
    Get:4 http://archive.ubuntu.com/ubuntu bionic/main amd64 python-minimal amd64 2.7.15~rc1-1 [28.1 kB]
    Get:5 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libpython2.7-stdlib amd64 2.7.17-1~18.04ubuntu1.6 [1917 kB]
    Get:6 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 python2.7 amd64 2.7.17-1~18.04ubuntu1.6 [248 kB]
    Get:7 http://archive.ubuntu.com/ubuntu bionic/main amd64 libpython-stdlib amd64 2.7.15~rc1-1 [7620 B]
    Get:8 http://archive.ubuntu.com/ubuntu bionic/main amd64 python amd64 2.7.15~rc1-1 [140 kB]
    Fetched 28.9 MB in 1s (21.0 MB/s)                              
    debconf: delaying package configuration, since apt-utils is not installed
    Selecting previously unselected package libpython2.7-minimal:amd64.
    (Reading database ... 5579 files and directories currently installed.)
    Preparing to unpack .../0-libpython2.7-minimal_2.7.17-1~18.04ubuntu1.6_amd64.deb ...
    Unpacking libpython2.7-minimal:amd64 (2.7.17-1~18.04ubuntu1.6) ...
    Selecting previously unselected package python2.7-minimal.
    Preparing to unpack .../1-python2.7-minimal_2.7.17-1~18.04ubuntu1.6_amd64.deb ...
    Unpacking python2.7-minimal (2.7.17-1~18.04ubuntu1.6) ...
    Selecting previously unselected package python-minimal.
    Preparing to unpack .../2-python-minimal_2.7.15~rc1-1_amd64.deb ...
    Unpacking python-minimal (2.7.15~rc1-1) ...
    Selecting previously unselected package libpython2.7-stdlib:amd64.
    Preparing to unpack .../3-libpython2.7-stdlib_2.7.17-1~18.04ubuntu1.6_amd64.deb ...
    Unpacking libpython2.7-stdlib:amd64 (2.7.17-1~18.04ubuntu1.6) ...
    Selecting previously unselected package python2.7.
    Preparing to unpack .../4-python2.7_2.7.17-1~18.04ubuntu1.6_amd64.deb ...
    Unpacking python2.7 (2.7.17-1~18.04ubuntu1.6) ...
    Selecting previously unselected package libpython-stdlib:amd64.
    Preparing to unpack .../5-libpython-stdlib_2.7.15~rc1-1_amd64.deb ...
    Unpacking libpython-stdlib:amd64 (2.7.15~rc1-1) ...
    Setting up libpython2.7-minimal:amd64 (2.7.17-1~18.04ubuntu1.6) ...
    Setting up python2.7-minimal (2.7.17-1~18.04ubuntu1.6) ...
    Linking and byte-compiling packages for runtime python2.7...
    Setting up python-minimal (2.7.15~rc1-1) ...
    Selecting previously unselected package python.
    (Reading database ... 6328 files and directories currently installed.)
    Preparing to unpack .../python_2.7.15~rc1-1_amd64.deb ...
    Unpacking python (2.7.15~rc1-1) ...
    Selecting previously unselected package nodejs.
    Preparing to unpack .../nodejs_14.17.0-1nodesource1_amd64.deb ...
    Unpacking nodejs (14.17.0-1nodesource1) ...
    Setting up nodejs (14.17.0-1nodesource1) ...
    Setting up libpython2.7-stdlib:amd64 (2.7.17-1~18.04ubuntu1.6) ...
    Setting up python2.7 (2.7.17-1~18.04ubuntu1.6) ...
    Setting up libpython-stdlib:amd64 (2.7.15~rc1-1) ...
    Setting up python (2.7.15~rc1-1) ...
    Processing triggers for mime-support (3.60ubuntu1) ...
    root@f0171301951f:/# node -v
    v14.17.0
    root@f0171301951f:/# npx -v
    6.14.13
    root@f0171301951f:/# which npx
    /usr/bin/npx
    root@f0171301951f:/# 

  • I can't see any npx. As far I see in the documentation, I didn't come across any npx. Could you let me know Please

Reply Children
  • npx is installed with Node.js on Ubuntu (it's part of the package manager npm).

    In your screenshot you can see it exists.

    For some reason (maybe you have configured an alias, or you changed your PATH variable), your system tries to execute it in `/usr/local/bin/npx`.

    You can solve this either by removing this alias, or by calling `/usr/bin/npx` or creating an alias in `/usr/local/bin/npx` -> `/usr/bin/npx` and then executing `npx`.

Related