<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Krishna Prasad Varma on Medium]]></title>
        <description><![CDATA[Stories by Krishna Prasad Varma on Medium]]></description>
        <link>https://medium.com/@kpvarma?source=rss-55c64f88b38------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*8XUpXpa7mJ04K4QRbPct1Q.png</url>
            <title>Stories by Krishna Prasad Varma on Medium</title>
            <link>https://medium.com/@kpvarma?source=rss-55c64f88b38------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 20:24:51 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@kpvarma/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Demystifying the ~/.gitconfig File: Understanding Git Configuration in INI Format]]></title>
            <link>https://medium.com/@kpvarma/demystifying-the-gitconfig-file-understanding-git-configuration-in-ini-format-41bcd282f33e?source=rss-55c64f88b38------2</link>
            <guid isPermaLink="false">https://medium.com/p/41bcd282f33e</guid>
            <category><![CDATA[git]]></category>
            <category><![CDATA[configuration]]></category>
            <category><![CDATA[github]]></category>
            <category><![CDATA[git-config]]></category>
            <dc:creator><![CDATA[Krishna Prasad Varma]]></dc:creator>
            <pubDate>Wed, 13 Dec 2023 23:12:15 GMT</pubDate>
            <atom:updated>2023-12-13T23:12:15.533Z</atom:updated>
            <content:encoded><![CDATA[<h3>Introduction</h3><p>As you dive into the world of Git, you’ll encounter the ~/.gitconfig file—a key component for configuring Git settings. This file, written in the INI (Initialization) format, holds global Git configurations specific to your user account. In this article, we&#39;ll explore the structure of the ~/.gitconfig file, its INI format, and how you can leverage it to tailor Git to your preferences.</p><h3>The INI Format</h3><p>INI (Initialization) files are a simple and widely used configuration file format. INI files became popular in the 1980s with the release of Windows 1.0. At the time, graphical user interfaces were gaining momentum, and developers needed a way to store application-specific settings that could be easily modified by users.</p><p>INI files provided a straightforward and human-readable format to accomplish this. INI files follow a hierarchical structure with sections and key-value pairs, making them easy to read and write.</p><h3>Structure of INI Files</h3><p>INI files have a straightforward structure consisting of sections, keys, and values. Here’s an example:</p><p>[section]<br>key1 = value1<br>key2 = value2</p><p>[another_section]<br>key3 = value3</p><p>The ~/.gitconfig file is written in a specific format called INI (Initialization) file format. It is a plain text format used to store configuration settings in key-value pairs.</p><p>In the INI file format, each configuration entry is represented by a section header enclosed in square brackets ([]), followed by one or more key-value pairs. The format is as follows:</p><pre>csharpCopy code</pre><pre>[section]<br>    key = value</pre><h3>Understanding the ~/.gitconfig File Format</h3><p>The ~/.gitconfig file follows a straightforward INI file format. Each configuration entry consists of a section header enclosed in square brackets, followed by one or more key-value pairs. Let&#39;s break down the structure:</p><p>Here’s an example of a ~/.gitconfig file in INI format:</p><pre>iniCopy code</pre><pre>[user]<br>    name = John Doe<br>    email = johndoe@example.com</pre><pre>[core]<br>    editor = nano</pre><pre>[color]<br>    ui = true</pre><p>In the example above, the [user] section contains the name and email keys with their corresponding values. Similarly, the [core] section has the editor key, and the [color] section has the ui key.</p><p>You can have multiple sections and key-value pairs in the ~/.gitconfig file to configure various aspects of Git&#39;s behavior and your personal preferences.</p><h3>Alternatives to INI Files</h3><p>While INI files continue to be used in various applications, alternative configuration file formats have gained popularity over time. Some alternatives include XML (eXtensible Markup Language), JSON (JavaScript Object Notation), YAML (YAML Ain’t Markup Language), and TOML (Tom’s Obvious, Minimal Language). These formats offer additional features, such as structured data, better support for complex hierarchies, and improved compatibility with modern programming languages.</p><h3><strong>Conclusion</strong></h3><p>INI files have a long history as a simple and versatile configuration file format. Their hierarchical structure, ease of use, and platform independence have made them a popular choice for storing initialization settings. While alternative formats have emerged, INI files continue to be utilized in various applications and systems, demonstrating their longevity and continued relevance in the realm of configuration management.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=41bcd282f33e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Simplifying SSH Connections with Named Hosts: A Step-by-Step Guide for beginners]]></title>
            <link>https://medium.com/@kpvarma/simplifying-ssh-connections-with-named-hosts-a-step-by-step-guide-for-beginners-2fde7c5f7a45?source=rss-55c64f88b38------2</link>
            <guid isPermaLink="false">https://medium.com/p/2fde7c5f7a45</guid>
            <category><![CDATA[ssh-configuration]]></category>
            <category><![CDATA[ssh]]></category>
            <category><![CDATA[mac]]></category>
            <dc:creator><![CDATA[Krishna Prasad Varma]]></dc:creator>
            <pubDate>Thu, 01 Jun 2023 02:14:02 GMT</pubDate>
            <atom:updated>2023-06-01T05:07:57.024Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oIbvzdxi1xaPLBARfxYYPA.png" /></figure><h3>Introduction</h3><p>As a beginner, you might want to connect to different servers using SSH. Manually typing lengthy connection commands each time can be cumbersome and prone to errors. However, by configuring your ~/.ssh/config file and utilizing named hosts, you can streamline your SSH connections and make your life much easier.</p><p>In this article, we will guide you through the process of setting up the ~/.ssh/config file and demonstrate how to log in to remote servers effortlessly using SSH.</p><h3>Understanding the SSH Config File</h3><p><strong>Step 1:</strong> The ~/.ssh/config file is located in your user&#39;s home directory. If the file does not exist, create it using the touch command a text editor like Ensure that the file has the correct permissions to protect your SSH configuration. Use your favourite editor. nano or vim or vi to edit the file.</p><pre>$ touch ~/.ssh/config<br>$ chmod 600 ~/.ssh/config<br>$ vi ~/.ssh/config</pre><p><strong>Step 2:</strong> The ~/.ssh/config file uses a simple syntax to define named hosts and their corresponding connection settings. Each named host consists of parameters defined within a block, like below:</p><pre>Host server1<br>    HostName example.com<br>    User username<br>    Port 22<br>    IdentityFile ~/.ssh/id_rsa</pre><p><strong>Step 3:</strong> To define a named host, specify a unique name after the “Host” keyword. This name will be used to reference the specific host when connecting via SSH. In the above example, the name of the host is server1. This allows you to connect to this Host via ssh using just this name ssh server1. SSH will automatically read your configuration from this file and form the appropriate command with parameters to execute.</p><p><strong>Step 4:</strong> Within each host block, you can set various parameters to define the connection details for that particular host. Some commonly used parameters include:</p><ul><li>HostName: Specifies the IP address or domain name of the remote server. You could also give multiple names separated with space. These will work like aliases.</li><li>User: Specifies the username to be used for authentication.</li><li>Port: Specifies the port number for the SSH connection. Default is 22.</li><li>IdentityFile: Specifies the path to the private key file for authentication. If not specified, SSH will try to use the default id_rsa file.</li><li>PreferredAuthentications: allows you to specify the preferred authentication methods in the order of preference. The most popular options arepublickey password keyboard-interactive . publickeyis the default and most secure authentication method. It uses SSH key pairs for authentication. If you have set up SSH keys on both the client and server, using this option ensures that SSH attempts public key-based authentication first. password option allows password-based authentication. When using this method, SSH will prompt you for the password associated with the specified username on the remote server. keyboard-interactive provides a more flexible authentication method that can support a variety of mechanisms, including password authentication and additional challenges. It can be used for systems that require an extra layer of authentication beyond passwords or SSH keys.</li></ul><p><strong>Step 5:</strong> Once you have defined named hosts in your ~/.ssh/config file, connecting to them becomes simple. Open your terminal and type ssh &lt;host_name&gt; to initiate an SSH connection. For example, to connect to server1, you would type ssh server1. If you have configured all the necessary parameters correctly, you will be prompted for your password or asked to select the appropriate private key for authentication.</p><h3>Additional tips</h3><p><strong>Tip 1</strong>: To save time, you can set up password-less authentication using SSH keys. This eliminates the need to enter a password or select a key each time you connect. Be sure to keep your private key secure and protected.</p><p><strong>Tip 2</strong>: You can use wildcards and patterns in the Host field to match multiple hosts with similar configurations. For example, Host *.example.com will match any host under the example.com domain.</p><p><strong>Tip 3</strong>: The UseKeychain directive in the SSH configuration file (~/.ssh/config) is specific to macOS systems. When set to yes, it instructs SSH to use the user&#39;s keychain to store and retrieve SSH keys for authentication.</p><p>Here’s what the UseKeychain directive does:</p><ol><li>Keychain Integration: The macOS Keychain is a secure storage system that stores various types of sensitive information, including passwords and encryption keys. When UseKeychain is set to yes, SSH will attempt to store the user&#39;s private SSH keys in the Keychain, so that they can be automatically retrieved and used for authentication when connecting to SSH servers.</li><li>Password Persistence: Additionally, when using password-based authentication, UseKeychain allows SSH to store the user&#39;s SSH password in the Keychain. This feature enables the automatic retrieval of passwords, avoiding the need to enter them every time an SSH connection is established.</li></ol><h3>Examples</h3><p><strong>Multiple Host Alias names</strong>: We can gave multiple names for a host. In the below example we gave 3 names to the same server aws_virginia_server, SV241 andmyblog.com, you can later connect to it using ssh aws_virginia_server or ssh SV241 or ssh myblog.com.</p><pre>Host aws_virginia_server SV241 myblog.com<br>    HostName example.com<br>    User username<br>    Port 22<br>    IdentityFile ~/.ssh/id_rsa</pre><p>Below will prompt you to enter the password for the username</p><pre>Host myserver<br>    HostName example.com<br>    User username<br>    PreferredAuthentications password</pre><h3>A more practical config file</h3><p>I have 2 github account and see how I have configured them. I also connect to multiple servers. See how I have configured mutiple aws servers in the below example.</p><pre>Host github.com<br>    IdentityFile ~/.ssh/id_rsa<br><br># Krishna1 Github Account<br>Host krishna1_github<br>    HostName github.com<br>    User git<br>    IdentityFile ~/.ssh/id_rsa_krishna1<br><br># Krishna1 Github Account<br>Host krishna2_github<br>    HostName github.com<br>    User git<br>    IdentityFile ~/.ssh/id_rsa_krishna2<br>    UseKeychain yes<br><br># ------------<br># AWS Servers<br># ------------<br><br># Client 1 (Ireland Region)<br># https://app.myproject.com/<br>Host client1 myproject app.myproject.com<br>    HostName 34.243.18.223<br>    User deployer<br>    IdentityFile ~/.ssh/id_rsa_aws_client_1<br>    UseKeychain yes<br><br># Client 2 (Ireland Region)<br># https://www.client2website.com/<br>Host client2 client2website www.client2website.com<br>    HostName 72.124.72.176<br>    User deployer<br>    IdentityFile ~/.ssh/id_rsa_aws_client_2<br>    UseKeychain yes</pre><p>Here is how I use these</p><pre><br># Check if the configuration and key is working. <br><br># Below uses ~/.ssh/id_rsa as configured<br>$ ssh -T git@github.com<br><br># Below will sign into the krishna1 github account <br># and uses ~/.ssh/id_rsa_krishna1<br>$ ssh -T git@krishna1github.com<br><br># Below will sign into the krishna2 github account <br># and uses ~/.ssh/id_rsa_krishna2<br>$ ssh -T git@krishna2github.com<br><br># Pull from the github repository (1st account)<br>$ git clone https://krishna1_github/example/repo.git<br><br># Pull from the github repository (2nd account)<br>$ git clone https://krishna2_github/example/repo.git<br><br># Connect to Client 1 AWS Server<br>$ ssh client1 # OR<br>$ ssh myproject # OR<br>$ ssh app.myproject.com<br><br># Connect to Client 2 AWS Server<br>$ ssh client2 # OR<br>$ ssh client2website # OR<br>$ ssh www.client2website.com</pre><h3>Conclusion</h3><p>Configuring the ~/.ssh/config file with named hosts can significantly simplify your SSH connections, especially when dealing with multiple servers. I hope the steps mentioned above helped you to streamline your SSH workflow, save time, and reduce the chances of errors while connecting to remote servers.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2fde7c5f7a45" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Adding Code Snippets to Your Medium.com Blog: A Beginner’s Guide]]></title>
            <link>https://medium.com/@kpvarma/adding-code-snippets-to-your-medium-com-blog-a-beginners-guide-c89c1f498ef8?source=rss-55c64f88b38------2</link>
            <guid isPermaLink="false">https://medium.com/p/c89c1f498ef8</guid>
            <category><![CDATA[blogging-tips]]></category>
            <category><![CDATA[codeformatter]]></category>
            <category><![CDATA[code-snippet]]></category>
            <dc:creator><![CDATA[Krishna Prasad Varma]]></dc:creator>
            <pubDate>Tue, 30 May 2023 02:29:13 GMT</pubDate>
            <atom:updated>2023-05-30T02:30:07.408Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/720/1*dihQgvtsfberinSXeqxoMQ.png" /></figure><h3><strong>Introduction</strong></h3><p>If you’re an aspiring young writer or blogger, Medium.com provides a fantastic platform to share your thoughts and ideas with a wide audience. Sometimes, you may want to include code snippets in your articles to demonstrate programming concepts or showcase specific code examples. In this article, we’ll walk you through the process of adding both inline code and block code to your Medium.com blog, using simple language that anyone can understand.</p><h3>Inline code</h3><p>Inline code refers to short snippets of code that are inserted within the text of your article. It helps highlight specific code elements or keywords. Here’s how you can add inline code on Medium.com:</p><p>Hit a single back tick character and start typing to have inline codes.</p><p>It will appear like this This is an inline code</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KclwJlGldKmH4c1gMi6YuQ.gif" /></figure><h3>Block code</h3><p>Block code refers to longer sections of code that require their own separate formatting and spacing. Here’s how you can add block code on Medium.com:</p><p>Hit back tick 3 times for block code.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UmjS4BXkXbRjnJba3CRnlg.gif" /></figure><p>Block code will look like below:</p><pre>&lt;!DOCTYPE html&gt;<br>&lt;html&gt;<br>&lt;head&gt;<br>    &lt;title&gt;Sample Page&lt;/title&gt;<br>&lt;/head&gt;<br>&lt;body&gt;<br>    &lt;header&gt;<br>        &lt;h1&gt;Welcome to My Website&lt;/h1&gt;<br>    &lt;/header&gt;<br>    <br>    &lt;main&gt;<br>        &lt;p&gt;This is a sample paragraph. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed gravida nibh vitae eros ultricies congue. Nulla facilisi. In hac habitasse platea dictumst.&lt;/p&gt;<br>    &lt;/main&gt;<br>&lt;/body&gt;<br>&lt;/html&gt;</pre><p>It will recognize the language automatically and will format them in most cases. You can also change the language at the top left when you mouse hover it</p><h3>Conclusion</h3><p>Incorporating code snippets into your Medium.com blog articles can enhance your explanations and make your content more engaging. By using backticks for inline code and three backticks for block code, you can easily highlight and showcase programming concepts and examples.</p><p>Remember to keep your explanations clear and concise, providing context and explanations alongside your code snippets. With these simple techniques, you’ll be able to write educational and informative articles that resonate with your readers on Medium.com.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c89c1f498ef8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using a Utility Docker Image for creating a new Node.js API]]></title>
            <link>https://medium.com/@kpvarma/using-a-utility-docker-image-for-node-js-50a1e0842310?source=rss-55c64f88b38------2</link>
            <guid isPermaLink="false">https://medium.com/p/50a1e0842310</guid>
            <category><![CDATA[setup-guide]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[docker-compose]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[utility-service]]></category>
            <dc:creator><![CDATA[Krishna Prasad Varma]]></dc:creator>
            <pubDate>Wed, 05 Apr 2023 08:01:00 GMT</pubDate>
            <atom:updated>2023-04-05T08:16:43.516Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/720/1*2suTNBvT1bBSjkMbihEk7w.png" /></figure><h3><strong>What are utility docker containers?</strong></h3><p>Docker utility containers are containers that are used to provide specific utility functions, rather than running applications or services. These containers can be used to perform a variety of tasks, such as monitoring, logging, debugging, and more.</p><p>Some examples of docker utility containers include:</p><ol><li><strong>Logspout</strong> — a utility container that collects logs from all containers running on a Docker host and forwards them to a log aggregator.</li><li><strong>Sysdig</strong> — a container that provides system-level monitoring and troubleshooting capabilities for containers and hosts.</li><li><strong>Nginx Proxy</strong> — a container that provides reverse proxy and load balancing capabilities for web services.</li><li><strong>Consul</strong> — a container that provides service discovery and configuration management capabilities for distributed systems.</li><li><strong>Docker Registry</strong> — a container that provides a centralized location for storing and distributing Docker images.</li></ol><p>Overall, Docker utility containers can be incredibly useful for simplifying the management and operation of containerized environments. By using these containers, users can easily add new functionality to their Docker environments without having to manually install and configure additional software.</p><h3>Why use a docker utility container to create a new node.js application?</h3><p>Using a utility container to create a Node.js application has several benefits, including:</p><ol><li><strong>Simplified development</strong>: By using a utility container, developers can easily set up a development environment that includes all the necessary dependencies and tools needed to build and test their applications. This can help to reduce the time and effort required to get up and running with a new Node.js project.</li><li><strong>Consistent environment</strong>: Docker utility containers provide a consistent environment for development and deployment, which can help to reduce the likelihood of errors and issues that can arise from differences in software versions and configurations across different environments.</li><li><strong>Isolation</strong>: Docker containers provide isolation for the Node.js application, which helps to prevent conflicts with other applications running on the same host machine. This can be especially useful when running multiple applications on the same server.</li></ol><h3>Prerequisite</h3><p>You’ll want to make sure you have the following components installed on your machine:</p><ul><li>Docker (Desktop download <a href="https://www.docker.com/get-started">here</a>, or <a href="https://www.docker.com/blog/download-and-try-the-tech-preview-of-docker-desktop-for-m1/">here</a> for Apple M1 chips)</li><li><a href="https://code.visualstudio.com/">VSCode</a></li></ul><h3>Lets Dive In</h3><p>Clone the utility-docker-images repository. This is a one-time task. Once this is set up, you could use the same utility container for creating multiple node.js applications.</p><pre>$ git clone git@github.com:kpvarma/utility-docker-images.git<br>$ cd utility-docker-images</pre><p>Build the docker image for node_utility</p><pre>$ docker-compose build node_utility</pre><p><strong>Starting the Node Utility</strong></p><p>Start the node_utility service in a container</p><pre>$ docker-compose run — rm node_utility init</pre><p>Replace the name new_app or new_api with what you like.</p><p>You will now see the node project files created in the node/new_app folder</p><p>You could now install any npm you need. whatever you type after node_utility is passed as the argument to the npm command running inside the docker utility container. Check the CMD command in Dockerfile to learn how this is done.</p><pre># for e.g to install Express.js, do like below:<br>$ docker-compose run --rm node_utility install express<br><br># Install multiple libraries<br>$ docker-compose run --rm node_utility install mongoose nodemon dotenv</pre><p>Alternatively, you could edit the node/new_app/package.json and add your desired dependencies and do an npm install in one go.</p><pre>$ docker-compose run — rm node_utility install</pre><p>Add Dockerfile and docker-compose.yml</p><pre>touch node/new_app/Dockerfile<br>touch node/new_app/docker-compose.yml</pre><p>Copy the content below to the newly created Dockerfile</p><pre>FROM node<br><br># Update and install required dependencies<br>RUN apt-get update &amp;&amp; apt-get install -y build-essential &amp;&amp; apt-get clean<br><br># Create a directory for the application<br>RUN mkdir /app<br>WORKDIR /app<br><br>COPY package.json /app<br>RUN npm install<br><br># Expose a port<br>EXPOSE 8002</pre><p>Copy the content below to the newly created Dockerfile</p><pre>version: &#39;3.9&#39;<br>services:<br>  nodejs:<br>    build:<br>      context: ./nodejs/image<br>    image: new_node_app:latest<br>    container_name: new_node_app<br>    command: [&quot;/bin/bash&quot;]<br>    tty: true<br>    stdin_open: true<br>    restart: always<br>    env_file:<br>      - ./nodejs/image/nodejs.env<br>    volumes:<br>      - ./nodejs/lessons:/app/lessons/<br>volumes:<br>  nodejs_lessons:</pre><p>You can now move the node/new_app folder outside of this folder where ever you wish and keep developing it.</p><pre>$ mv node/new_app ~/Projects/2023/new_project_name</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=50a1e0842310" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Install node.js on Mac OSx (Updated Mar 2023)]]></title>
            <link>https://medium.com/@kpvarma/install-node-js-on-mac-osx-updated-mar-2023-23fb33d0eae8?source=rss-55c64f88b38------2</link>
            <guid isPermaLink="false">https://medium.com/p/23fb33d0eae8</guid>
            <category><![CDATA[mac]]></category>
            <category><![CDATA[installation]]></category>
            <category><![CDATA[nodejs]]></category>
            <dc:creator><![CDATA[Krishna Prasad Varma]]></dc:creator>
            <pubDate>Wed, 05 Apr 2023 06:35:16 GMT</pubDate>
            <atom:updated>2023-04-05T06:35:16.245Z</atom:updated>
            <content:encoded><![CDATA[<ol><li>Open the Terminal app.</li><li>Install Homebrew package manager by entering the command “/bin/bash -c “$(curl -fsSL <a href="https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh">https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh</a>)&quot;&quot;.</li><li>Install Node.js by running the command “brew install node”.</li><li>Verify that Node.js is installed by typing “node -v” in the Terminal.</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=23fb33d0eae8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Install node.js on Linux (Updated Mar 2023)]]></title>
            <link>https://medium.com/@kpvarma/install-node-js-on-linux-updated-mar-2023-4d7feffa13c0?source=rss-55c64f88b38------2</link>
            <guid isPermaLink="false">https://medium.com/p/4d7feffa13c0</guid>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[installation]]></category>
            <category><![CDATA[nodejs]]></category>
            <dc:creator><![CDATA[Krishna Prasad Varma]]></dc:creator>
            <pubDate>Mon, 03 Apr 2023 05:11:45 GMT</pubDate>
            <atom:updated>2023-04-03T05:11:45.486Z</atom:updated>
            <content:encoded><![CDATA[<h3><strong>Installing Node.js on Linux:</strong></h3><p><strong>Step 1:</strong> Update your package list. Open your terminal and run the command:</p><pre>$ sudo apt-get update</pre><p><strong>Step 2:</strong> Install the required dependencies: Node.js requires some dependencies to be installed to work correctly. Run the following command in your terminal:</p><pre>$ sudo apt-get install -y curl dirmngr apt-transport-https lsb-release ca-certificates</pre><p><strong>Step 3:</strong> Import the Node.js GPG key: To verify the authenticity of the Node.js software packages, you’ll need to import the GPG key into your system. Run the following command in your terminal:</p><pre>$ curl -sL https://deb.nodesource.com/setup_16.x | sudo -E bash -</pre><p>Note: Replace ‘16’ in the above command with your required Node.js version.</p><p><strong><em>More about GPG Key</em></strong></p><p>Node.js GPG (GNU Privacy Guard) key is a cryptographic key used for verifying the authenticity of Node.js downloads. It is a security feature implemented by the Node.js team to ensure that the downloaded packages have not been tampered with and are from a trusted source.</p><p>The GPG key is used to sign the checksum files, which are then used to verify the integrity of the downloaded package. This helps in preventing any malicious activity or tampering with the downloaded files.</p><p>To verify the authenticity of the Node.js packages, users can download the GPG key from the official Node.js website and use it to verify the downloaded package. This ensures that the downloaded package is genuine and has not been modified or tampered with in any way.</p><p><strong>Step 4:</strong> Install Node.js: Once the GPG key is imported, you can install Node.js using the following command:</p><pre>$ sudo apt-get install -y nodejs</pre><p><strong>Step 5:</strong> Verify the installation: After the installation is complete, verify that Node.js is installed by running the following command:</p><pre>$ node -v</pre><p>This command will display the version of Node.js installed on your system.</p><p><strong>Step 6:</strong> (Optional) Install the build tools: If you plan on building native modules for Node.js, you’ll need to install the build tools. You can install them by running the following command:</p><pre>$ sudo apt-get install -y build-essential</pre><p>That’s it! You now have Node.js installed on your Linux system.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4d7feffa13c0" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>