<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: S Karthik</title>
    <description>The latest articles on DEV Community by S Karthik (@karthiksdevopsengineer).</description>
    <link>https://dev.to/karthiksdevopsengineer</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1599718%2Fdabc964c-7bfd-4d4a-a6a9-4ecbb85e0c7b.jpg</url>
      <title>DEV Community: S Karthik</title>
      <link>https://dev.to/karthiksdevopsengineer</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/karthiksdevopsengineer"/>
    <language>en</language>
    <item>
      <title>Securing Your Application with HTTP Basic Authentication in Nginx</title>
      <dc:creator>S Karthik</dc:creator>
      <pubDate>Sat, 22 Jun 2024 09:01:59 +0000</pubDate>
      <link>https://dev.to/karthiksdevopsengineer/securing-your-application-with-http-basic-authentication-in-nginx-3fj6</link>
      <guid>https://dev.to/karthiksdevopsengineer/securing-your-application-with-http-basic-authentication-in-nginx-3fj6</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;In this guide, we’ll walk you through setting up HTTP Basic Authentication for your application using Nginx. This will help you add an extra layer of security by requiring a username and password to access your application.&lt;/p&gt;

&lt;h2&gt;
  
  
  Setup Instructions
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Step 1: Install Apache Utilities&lt;/strong&gt;&lt;br&gt;
First, we need to install apache2-utils, which provides the htpasswd utility for creating password files. I’m using an Ubuntu machine, so I have installed apache2-utils using the following commands.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt update
sudo apt install apache2-utils
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Step 2: Create the Password File&lt;/strong&gt;&lt;br&gt;
Next, we’ll create a password file that Nginx will use to authenticate users. We’ll store this file in /etc/apache2/.htpasswd.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo htpasswd -c /etc/apache2/.htpasswd yourusername
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Replace yourusername with the username you want to use. You'll be prompted to enter and confirm a password.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 3: Configure Nginx&lt;/strong&gt;&lt;br&gt;
Now, we need to modify the Nginx configuration to use this password file. Open your Nginx configuration file at /etc/nginx/sites-available/yourconfigfile&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;server {
    listen 80;
    server_name yourdomain.com;

    location / {
        proxy_pass http://localhost:YOUR_APPLICATION_PORT;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;

        auth_basic "Restricted Access";
        auth_basic_user_file /etc/apache2/.htpasswd;
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Replace yourdomain.com with your actual domain name and YOUR_APPLICATION_PORT with the port your application is running on. This configuration tells Nginx to forward requests to your application and to use basic authentication with the credentials stored in /etc/apache2/.htpasswd.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 4: Enable the Configuration&lt;/strong&gt;&lt;br&gt;
Create a symbolic link from your configuration file in sites-available to sites-enabled to enable it in Nginx.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo ln -s /etc/nginx/sites-available/yourconfigfile /etc/nginx/sites-enabled/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Replace yourconfigfile with the name of your Nginx configuration file.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 5: Test the Nginx Configuration&lt;/strong&gt;&lt;br&gt;
Before restarting Nginx, it’s a good idea to test the configuration to ensure there are no syntax errors.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo nginx -t
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Step 6: Restart Nginx&lt;/strong&gt;&lt;br&gt;
Finally, restart Nginx to apply the new configuration.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo systemctl restart nginx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;br&gt;
Your application is now protected with HTTP Basic Authentication. When users attempt to access your site, they will be prompted to enter the username and password you configured. This added layer of security helps protect your application from unauthorized access.&lt;/p&gt;

</description>
      <category>nginx</category>
      <category>security</category>
      <category>cloud</category>
      <category>http</category>
    </item>
    <item>
      <title>Configuring Nginx for IP Redirection and Domain Configuration</title>
      <dc:creator>S Karthik</dc:creator>
      <pubDate>Wed, 19 Jun 2024 02:22:00 +0000</pubDate>
      <link>https://dev.to/karthiksdevopsengineer/configuring-nginx-for-ip-redirection-and-domain-configuration-232g</link>
      <guid>https://dev.to/karthiksdevopsengineer/configuring-nginx-for-ip-redirection-and-domain-configuration-232g</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Nginx, a powerful web server, can efficiently manage web traffic and serve multiple applications simultaneously. In this beginner-friendly guide, we’ll explore how to set up IP to domain redirection and application proxying using Nginx.&lt;/p&gt;

&lt;h2&gt;
  
  
  Configuring IP Address to Domain Redirection and Application Proxying
&lt;/h2&gt;

&lt;p&gt;Navigate to your Nginx configuration file, typically located at &lt;code&gt;/etc/nginx/sites-available/&amp;lt;your-file&amp;gt;&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;server {
    listen 80;
    server_name &amp;lt;server-ip&amp;gt;;

    location / {
        return 301 http://&amp;lt;dns-name&amp;gt;$request_uri;
    }
}

server {
    listen 80;
    server_name &amp;lt;dns-name&amp;gt;;

    location / {
        proxy_pass http://localhost:&amp;lt;port&amp;gt;;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Explanation
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;IP Redirection:&lt;/strong&gt; The first server block listens on port 80 for requests directed to the specified &lt;code&gt;&amp;lt;server-ip&amp;gt;&lt;/code&gt;. It then issues a 301 redirect to the designated &lt;code&gt;&amp;lt;dns-name&amp;gt;&lt;/code&gt; for all incoming requests.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Domain Configuration:&lt;/strong&gt; The second server block listens on port 80 for requests directed to the &lt;code&gt;&amp;lt;dns-name&amp;gt;&lt;/code&gt;. It proxies the incoming traffic to the application running on &lt;code&gt;http://localhost:&amp;lt;port&amp;gt;&lt;/code&gt;, ensuring seamless communication between Nginx and your application.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;That’s it! You’ve successfully configured Nginx to redirect traffic from an IP address to a domain name. Now, whenever someone accesses your application using the IP address, they will be automatically redirected to the specified domain name.&lt;/p&gt;

</description>
      <category>nginx</category>
      <category>devops</category>
      <category>linux</category>
      <category>cloud</category>
    </item>
    <item>
      <title>Setting Up Elasticsearch and Kibana Single-Node with Docker Compose</title>
      <dc:creator>S Karthik</dc:creator>
      <pubDate>Tue, 18 Jun 2024 03:15:08 +0000</pubDate>
      <link>https://dev.to/karthiksdevopsengineer/setting-up-elasticsearch-and-kibana-single-node-with-docker-compose-74j</link>
      <guid>https://dev.to/karthiksdevopsengineer/setting-up-elasticsearch-and-kibana-single-node-with-docker-compose-74j</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Setting up Elasticsearch and Kibana on a single-node cluster can be a straightforward process with Docker Compose. In this guide, we’ll walk through the steps to get your Elasticsearch and Kibana instances up and running smoothly.&lt;/p&gt;

&lt;h2&gt;
  
  
  Hardware Prerequisites
&lt;/h2&gt;

&lt;p&gt;According to the Elastic Cloud Enterprise documentation, here are the hardware requirements for running Elasticsearch and Kibana&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;CPU:&lt;/strong&gt; A minimum of 2 CPU cores is recommended, but the actual requirement depends on your workload. More CPU cores may be required for intensive tasks or larger datasets.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;RAM:&lt;/strong&gt; Elastic recommends a minimum of 8GB of RAM for Elasticsearch, but 16GB or more is recommended for production use, especially when running both Elasticsearch and Kibana on the same machine.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Storage:&lt;/strong&gt; SSD storage is recommended for better performance, especially for production use. The amount of storage required depends on your data volume and retention policies.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For more detailed hardware requirements and recommendations, refer to the &lt;a href="https://www.elastic.co/guide/en/cloud-enterprise/current/ece-hardware-prereq.html#ece-hardware-prereq"&gt;Elastic Cloud Enterprise documentation.&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Software Prerequisites
&lt;/h2&gt;

&lt;p&gt;Before getting started, make sure you have Docker installed on your system. You can download and install Docker from the &lt;a href="https://docs.docker.com/engine/install/"&gt;official website&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Setting Up Instructions
&lt;/h2&gt;

&lt;p&gt;In this guide, I will perform these operations with the following specifications.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;OS:&lt;/strong&gt; Ubuntu 22.04&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;RAM:&lt;/strong&gt; 8GB&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Storage:&lt;/strong&gt; 30GB SSD&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;1. Adjust Kernel Settings&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;vm.max_map_count&lt;/code&gt; kernel setting must be set to at least &lt;code&gt;262144&lt;/code&gt;. How you set &lt;code&gt;vm.max_map_count&lt;/code&gt; depends on your platform. &lt;a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/docker.html#_set_vm_max_map_count_to_at_least_262144"&gt;For more information&lt;/a&gt;. I’m using the Linux operating system, so I will set vm.max_map_count using as follows&lt;/p&gt;

&lt;p&gt;Open the &lt;code&gt;/etc/sysctl.conf&lt;/code&gt; file in a text editor with root privileges. You can use the following command&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo nano /etc/sysctl.conf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Navigate to the end of the file or search for the line containing &lt;code&gt;vm.max_map_count&lt;/code&gt;, If the line exists, modify it to set the desired value&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;vm.max_map_count=262144
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If the line doesn’t exist, add it at the end of the file&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# Set vm.max_map_count to increase memory map areas
vm.max_map_count=262144
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Save the file and exit the text editor. Apply the changes by running the following command&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo sysctl -p
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This command reloads the sysctl settings from the configuration file. Now, the value of &lt;code&gt;vm.max_map_count&lt;/code&gt; should be updated to &lt;code&gt;262144&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Prepare Environment Variables&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Create or navigate to an empty directory for the project. Inside this directory, create a &lt;code&gt;.env&lt;/code&gt; file and set up the necessary environment variables.&lt;/p&gt;

&lt;p&gt;Copy the following content and paste it into the &lt;code&gt;.env&lt;/code&gt; file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# Password for the 'elastic' user (at least 6 characters)
ELASTIC_PASSWORD=

# Password for the 'kibana_system' user (at least 6 characters)
KIBANA_PASSWORD=

# Version of Elastic products
STACK_VERSION={version}

# Set the cluster name
CLUSTER_NAME=docker-cluster

# Set to 'basic' or 'trial' to automatically start the 30-day trial
LICENSE=basic

# Port to expose Elasticsearch HTTP API to the host
ES_PORT=9200

# Port to expose Kibana to the host
KIBANA_PORT=5601

# Increase or decrease based on the available host memory (in bytes)
MEM_LIMIT=2147483648
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the &lt;code&gt;.env file&lt;/code&gt;, specify a password for the &lt;code&gt;ELASTIC_PASSWORD&lt;/code&gt; and &lt;code&gt;KIBANA_PASSWORD&lt;/code&gt; variables.&lt;/p&gt;

&lt;p&gt;The passwords must be alphanumeric and can’t contain special characters, such as &lt;code&gt;!&lt;/code&gt; or &lt;code&gt;@&lt;/code&gt;. The bash script included in the &lt;code&gt;compose.yml&lt;/code&gt; file only works with alphanumeric characters. Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# Password for the 'elastic' user (at least 6 characters)
ELASTIC_PASSWORD=Secure123

# Password for the 'kibana_system' user (at least 6 characters)
KIBANA_PASSWORD=Secure123

...
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the &lt;code&gt;.env&lt;/code&gt; file, set &lt;code&gt;STACK_VERSION&lt;/code&gt; to the Elastic Stack version. Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;...

# Version of Elastic products
STACK_VERSION=8.13.2

...
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;3. Create Docker Compose Configuration&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Now, create a &lt;code&gt;compose.yml&lt;/code&gt; file in the same directory and copy the following content and paste it into the &lt;code&gt;compose.yml&lt;/code&gt; file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;version: "2.2"

services:
  setup:
    image: docker.elastic.co/elasticsearch/elasticsearch:${STACK_VERSION}
    volumes:
      - certs:/usr/share/elasticsearch/config/certs
    user: "0"
    command: &amp;gt;
      bash -c '
        if [ x${ELASTIC_PASSWORD} == x ]; then
          echo "Set the ELASTIC_PASSWORD environment variable in the .env file";
          exit 1;
        elif [ x${KIBANA_PASSWORD} == x ]; then
          echo "Set the KIBANA_PASSWORD environment variable in the .env file";
          exit 1;
        fi;
        if [ ! -f config/certs/ca.zip ]; then
          echo "Creating CA";
          bin/elasticsearch-certutil ca --silent --pem -out config/certs/ca.zip;
          unzip config/certs/ca.zip -d config/certs;
        fi;
        if [ ! -f config/certs/certs.zip ]; then
          echo "Creating certs";
          echo -ne \
          "instances:\n"\
          "  - name: es01\n"\
          "    dns:\n"\
          "      - es01\n"\
          "      - localhost\n"\
          "    ip:\n"\
          "      - 127.0.0.1\n"\
          &amp;gt; config/certs/instances.yml;
          bin/elasticsearch-certutil cert --silent --pem -out config/certs/certs.zip --in config/certs/instances.yml --ca-cert config/certs/ca/ca.crt --ca-key config/certs/ca/ca.key;
          unzip config/certs/certs.zip -d config/certs;
        fi;
        echo "Setting file permissions"
        chown -R root:root config/certs;
        find . -type d -exec chmod 750 \{\} \;;
        find . -type f -exec chmod 640 \{\} \;;
        echo "Waiting for Elasticsearch availability";
        until curl -s --cacert config/certs/ca/ca.crt https://es01:9200 | grep -q "missing authentication credentials"; do sleep 30; done;
        echo "Setting kibana_system password";
        until curl -s -X POST --cacert config/certs/ca/ca.crt -u "elastic:${ELASTIC_PASSWORD}" -H "Content-Type: application/json" https://es01:9200/_security/user/kibana_system/_password -d "{\"password\":\"${KIBANA_PASSWORD}\"}" | grep -q "^{}"; do sleep 10; done;
        echo "All done!";
      '
    healthcheck:
      test: ["CMD-SHELL", "[ -f config/certs/es01/es01.crt ]"]
      interval: 1s
      timeout: 5s
      retries: 120

  es01:
    image: docker.elastic.co/elasticsearch/elasticsearch:${STACK_VERSION}
    volumes:
      - certs:/usr/share/elasticsearch/config/certs
      - esdata:/usr/share/elasticsearch/data
    ports:
      - ${ES_PORT}:9200
    environment:
      - node.name=es01
      - cluster.name=${CLUSTER_NAME}
      - discovery.type=single-node
      - ELASTIC_PASSWORD=${ELASTIC_PASSWORD}
      - bootstrap.memory_lock=true
      - xpack.security.enabled=true
      - xpack.security.http.ssl.enabled=true
      - xpack.security.http.ssl.key=certs/es01/es01.key
      - xpack.security.http.ssl.certificate=certs/es01/es01.crt
      - xpack.security.http.ssl.certificate_authorities=certs/ca/ca.crt
      - xpack.security.transport.ssl.enabled=true
      - xpack.security.transport.ssl.key=certs/es01/es01.key
      - xpack.security.transport.ssl.certificate=certs/es01/es01.crt
      - xpack.security.transport.ssl.certificate_authorities=certs/ca/ca.crt
      - xpack.security.transport.ssl.verification_mode=certificate
      - xpack.license.self_generated.type=${LICENSE}
    mem_limit: ${MEM_LIMIT}
    ulimits:
      memlock:
        soft: -1
        hard: -1
    healthcheck:
      test:
        [
          "CMD-SHELL",
          "curl -s --cacert config/certs/ca/ca.crt https://localhost:9200 | grep -q 'missing authentication credentials'",
        ]
      interval: 10s
      timeout: 10s
      retries: 120

  kibana:
    depends_on:
      es01:
        condition: service_healthy
    image: docker.elastic.co/kibana/kibana:${STACK_VERSION}
    volumes:
      - certs:/usr/share/kibana/config/certs
      - kibanadata:/usr/share/kibana/data
    ports:
      - ${KIBANA_PORT}:5601
    environment:
      - SERVERNAME=kibana
      - ELASTICSEARCH_HOSTS=https://es01:9200
      - ELASTICSEARCH_USERNAME=kibana_system
      - ELASTICSEARCH_PASSWORD=${KIBANA_PASSWORD}
      - ELASTICSEARCH_SSL_CERTIFICATEAUTHORITIES=config/certs/ca/ca.crt
      - SERVER_PUBLICBASEURL=http://localhost:5601
    mem_limit: ${MEM_LIMIT}
    healthcheck:
      test:
        [
          "CMD-SHELL",
          "curl -s -I http://localhost:5601 | grep -q 'HTTP/1.1 302 Found'",
        ]
      interval: 10s
      timeout: 10s
      retries: 120

volumes:
  certs:
    driver: local
  esdata:
    driver: local
  kibanadata:
    driver: local
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;4. Start Docker Compose&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Now you can start Elasticsearch and Kibana using Docker Compose. Run the following command from your project directory&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;docker compose up -d
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;5. Access Elasticsearch and Kibana&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Once Docker Compose has started the services, you can access Elasticsearch at &lt;code&gt;https://&amp;lt;localhost or serverip&amp;gt;:9200&lt;/code&gt; and Kibana at &lt;code&gt;http://&amp;lt;localhost or serverip&amp;gt;:5601&lt;/code&gt; in your web browser.&lt;/p&gt;

&lt;p&gt;Log in to Elasticsearch or Kibana as the elastic user and the password is the one you set earlier in the &lt;code&gt;.env&lt;/code&gt; file.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;You’ve successfully set up Elasticsearch and Kibana on a single-node using Docker Compose.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Reference&lt;/strong&gt; &lt;a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/docker.html"&gt;https://www.elastic.co/guide/en/elasticsearch/reference/current/docker.html&lt;/a&gt;&lt;/p&gt;

</description>
      <category>elasticsearch</category>
      <category>docker</category>
      <category>tutorial</category>
      <category>devops</category>
    </item>
    <item>
      <title>Azure Resource Naming Conventions! Best Practices for Optimal Management</title>
      <dc:creator>S Karthik</dc:creator>
      <pubDate>Mon, 17 Jun 2024 02:23:30 +0000</pubDate>
      <link>https://dev.to/karthiksdevopsengineer/azure-resource-naming-conventions-best-practices-for-optimal-management-9d0</link>
      <guid>https://dev.to/karthiksdevopsengineer/azure-resource-naming-conventions-best-practices-for-optimal-management-9d0</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;In the vast landscape of Azure cloud services, effective resource management is paramount. One often-overlooked aspect that significantly contributes to efficient management is a well-defined naming convention. In this guide, we’ll delve into crafting and implementing an effective Azure resource naming convention, using a structured approach that enhances clarity, organization, and scalability.&lt;/p&gt;

&lt;h2&gt;
  
  
  Understanding the Components
&lt;/h2&gt;

&lt;p&gt;In our proposed Azure resource naming convention, each component serves a distinct purpose&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Resource Type:&lt;/strong&gt; Indicates the specific service or resource type (e.g., VM, SQL, Storage).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Application or Project name:&lt;/strong&gt; Identifies the associated application or project.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Environment:&lt;/strong&gt; Specifies the environment of the Application or Project (e.g., development, production).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Region:&lt;/strong&gt; Denotes the Azure region where the resource is deployed.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Unique identifier:&lt;/strong&gt; Provides a unique reference for the particular resource.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Benefits of Consistent Naming Conventions
&lt;/h2&gt;

&lt;p&gt;Implementing a standardized naming convention offers numerous advantages&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Clarity and Readability:&lt;/strong&gt; Clear, descriptive names enhance understanding and facilitate communication.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Ease of Resource Identification:&lt;/strong&gt; Consistent naming simplifies locating and managing resources across environments.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Simplified Management and Organization:&lt;/strong&gt; Well-named resources streamline administrative tasks and improve overall resource governance.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Best Practices for Implementing Naming Conventions
&lt;/h2&gt;

&lt;p&gt;To ensure the effectiveness of your naming conventions, adhere to these best practices&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Consistency:&lt;/strong&gt; Maintain uniformity across all resources within your Azure environment.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Descriptive Naming:&lt;/strong&gt; Use meaningful names that accurately reflect the purpose and function of each resource.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Metadata Incorporation:&lt;/strong&gt; Include relevant metadata, such as environment, region, or department, to provide additional context.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Documentation:&lt;/strong&gt; Document the naming conventions comprehensively for team reference and future scalability.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Example Use Cases
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdcf1e81ae7fqayv0idha.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdcf1e81ae7fqayv0idha.png" alt="Image description" width="670" height="194"&gt;&lt;/a&gt;&lt;br&gt;
Let’s explore practical scenarios demonstrating the application of our naming convention&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Production Environments:&lt;/strong&gt; rg-sharepoint-prod-westus-001&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Development Environments:&lt;/strong&gt; rg-sharepoint-dev-eastus-002&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Various Azure Regions:&lt;/strong&gt; rg-sharepoint-prod-centralus-003&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Different Resource Types:&lt;/strong&gt; rg-sql-db-dev-westus-004&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Crafting an effective Azure resource naming convention is not merely a matter of syntax; it’s a strategic approach to streamline resource management, enhance collaboration, and ensure scalability. By adopting the structured approach outlined in this guide, organizations can establish a robust foundation for efficient Azure resource governance. Embrace consistency, clarity, and documentation to master Azure resource naming conventions and unlock the full potential of your cloud environment.&lt;/p&gt;

</description>
      <category>azure</category>
      <category>microsoft</category>
      <category>cloudcomputing</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
