{"id":6907,"date":"2022-10-20T20:15:36","date_gmt":"2022-10-20T20:15:36","guid":{"rendered":"https:\/\/www.geekdecoder.com\/?p=6907"},"modified":"2022-10-20T20:15:36","modified_gmt":"2022-10-20T20:15:36","slug":"install-node-js-on-debian-11-bullseye","status":"publish","type":"post","link":"https:\/\/www.qbytes.cloud\/index.php\/2022\/10\/20\/install-node-js-on-debian-11-bullseye\/","title":{"rendered":"Install Node.js on Debian 11 (bullseye)"},"content":{"rendered":"\n<p>For this article, we will install NodeJS19 on a Debian 11 (bullseye) system. Here are the installation instructions:<br><\/p>\n\n\n\n<!--more-->\n\n\n\n<p>Node.js v19.x:<br>Using Debian, as root<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ncurl -fsSL https:\/\/deb.nodesource.com\/setup_19.x | bash - &amp;&amp;\\\napt-get install -y nodejs\n<\/pre><\/div>\n\n\n<p>Output:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n## Installing the NodeSource Node.js 19.x repo...\n\n## Populating apt-get cache...\n\n+ apt-get update\nHit:1 http:\/\/security.debian.org\/debian-security bullseye-security InRelease\nHit:2 http:\/\/deb.debian.org\/debian bullseye InRelease\nHit:3 http:\/\/deb.debian.org\/debian bullseye-updates InRelease\nIgn:4 http:\/\/repo.mongodb.org\/apt\/debian bullseye\/mongodb-org\/6.0 InRelease\nHit:5 http:\/\/repo.mongodb.org\/apt\/debian bullseye\/mongodb-org\/6.0 Release\nReading package lists... Done\n\n## Confirming \"bullseye\" is supported...\n\n+ curl -sLf -o \/dev\/null 'https:\/\/deb.nodesource.com\/node_19.x\/dists\/bullseye\/Release'\n\n## Adding the NodeSource signing key to your keyring...\n\n+ curl -s https:\/\/deb.nodesource.com\/gpgkey\/nodesource.gpg.key | gpg --dearmor | tee \/usr\/share\/keyrings\/nodesource.gpg &gt;\/dev\/null\n\n## Creating apt sources list file for the NodeSource Node.js 19.x repo...\n\n+ echo 'deb &#x5B;signed-by=\/usr\/share\/keyrings\/nodesource.gpg] https:\/\/deb.nodesource.com\/node_19.x bullseye main' &gt; \/etc\/apt\/sources.list.d\/nodesource.list\n+ echo 'deb-src &#x5B;signed-by=\/usr\/share\/keyrings\/nodesource.gpg] https:\/\/deb.nodesource.com\/node_19.x bullseye main' &gt;&gt; \/etc\/apt\/sources.list.d\/nodesource.list\n\n## Running `apt-get update` for you...\n\n+ apt-get update\nHit:1 http:\/\/deb.debian.org\/debian bullseye InRelease\nHit:2 http:\/\/security.debian.org\/debian-security bullseye-security InRelease\nHit:3 http:\/\/deb.debian.org\/debian bullseye-updates InRelease\nIgn:4 http:\/\/repo.mongodb.org\/apt\/debian bullseye\/mongodb-org\/6.0 InRelease\nHit:5 http:\/\/repo.mongodb.org\/apt\/debian bullseye\/mongodb-org\/6.0 Release\nGet:7 https:\/\/deb.nodesource.com\/node_19.x bullseye InRelease &#x5B;4,586 B]\nGet:8 https:\/\/deb.nodesource.com\/node_19.x bullseye\/main amd64 Packages &#x5B;771 B]\nFetched 5,357 B in 1s (5,528 B\/s)\nReading package lists... Done\n\n## Run `sudo apt-get install -y nodejs` to install Node.js 19.x and npm\n## You may also need development tools to build native addons:\n     sudo apt-get install gcc g++ make\n## To install the Yarn package manager, run:\n     curl -sL https:\/\/dl.yarnpkg.com\/debian\/pubkey.gpg | gpg --dearmor | sudo tee \/usr\/share\/keyrings\/yarnkey.gpg &gt;\/dev\/null\n     echo \"deb &#x5B;signed-by=\/usr\/share\/keyrings\/yarnkey.gpg] https:\/\/dl.yarnpkg.com\/debian stable main\" | sudo tee \/etc\/apt\/sources.list.d\/yarn.list\n     sudo apt-get update &amp;&amp; sudo apt-get install yarn\n\nReading package lists... Done\nBuilding dependency tree... Done\nReading state information... Done\nThe following NEW packages will be installed:\n  nodejs\n0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.\nNeed to get 29.0 MB of archives.\nAfter this operation, 183 MB of additional disk space will be used.\nGet:1 https:\/\/deb.nodesource.com\/node_19.x bullseye\/main amd64 nodejs amd64 19.0.0-deb-1nodesource1 &#x5B;29.0 MB]\nFetched 29.0 MB in 2s (17.8 MB\/s)\nSelecting previously unselected package nodejs.\n(Reading database ... 35562 files and directories currently installed.)\nPreparing to unpack ...\/nodejs_19.0.0-deb-1nodesource1_amd64.deb ...\nUnpacking nodejs (19.0.0-deb-1nodesource1) ...\nSetting up nodejs (19.0.0-deb-1nodesource1) ...\nProcessing triggers for man-db (2.9.4-2) ...\n<\/pre><\/div>\n\n\n<pre class=\"wp-block-preformatted\">\n\n\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>For this article, we will install NodeJS19 on a Debian 11 (bullseye) system. Here are the installation instructions:<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[56],"tags":[],"class_list":["post-6907","post","type-post","status-publish","format-standard","hentry","category-kb"],"_links":{"self":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts\/6907","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/comments?post=6907"}],"version-history":[{"count":0,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts\/6907\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/media?parent=6907"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/categories?post=6907"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/tags?post=6907"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}