<?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: Ayodeji Adesola</title>
    <description>The latest articles on DEV Community by Ayodeji Adesola (@theprotonguy).</description>
    <link>https://dev.to/theprotonguy</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%2F1468465%2F25b81908-42e9-443e-83f0-0ec2d6a9834e.jpeg</url>
      <title>DEV Community: Ayodeji Adesola</title>
      <link>https://dev.to/theprotonguy</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/theprotonguy"/>
    <language>en</language>
    <item>
      <title>Setting Up a Highly Available Azure Storage Account with Public Access and Blob Management Features</title>
      <dc:creator>Ayodeji Adesola</dc:creator>
      <pubDate>Fri, 13 Sep 2024 08:55:44 +0000</pubDate>
      <link>https://dev.to/theprotonguy/setting-up-a-highly-available-azure-storage-account-with-public-access-and-blob-management-features-54da</link>
      <guid>https://dev.to/theprotonguy/setting-up-a-highly-available-azure-storage-account-with-public-access-and-blob-management-features-54da</guid>
      <description>&lt;p&gt;Recently, I worked on setting up a highly available storage account in Azure to support a public website. My goal was to ensure the storage account had high availability, enabled anonymous public access, and included additional features like soft delete and blob versioning. Here's a breakdown of the steps I followed and some key takeaways from the process.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 1: Creating a Highly Available Storage Account&lt;/strong&gt;&lt;br&gt;
To begin, I created a new storage account that would support the public website. I headed to the Azure portal, searched for "Storage accounts," and selected the "+ Create" option. For organization, I created a new resource group, gave it a name, and set up the storage account with a unique name (publicwebsite followed by an identifier to ensure uniqueness). I took the default settings for most of the configuration and proceeded to deploy the storage account.&lt;/p&gt;

&lt;p&gt;Since this setup requires high availability, I needed to prepare for any potential regional outages. In the storage account settings under the "Redundancy" blade, I selected the "Read-access Geo-redundant storage" (RA-GRS) option. This setting not only provides geo-redundancy but also ensures that data can be read from a secondary region if the primary region goes down—a critical aspect for high availability.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 2: Enabling Anonymous Public Access&lt;/strong&gt;&lt;br&gt;
To ensure that information on the public website could be accessed without requiring customer logins, I configured the storage account to allow anonymous access to blobs. In the storage account’s "Configuration" settings, I enabled the "Allow blob anonymous access" option. This setting is essential for a public-facing website where users should be able to view content without barriers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 3: Creating a Blob Storage Container with Anonymous Read Access&lt;/strong&gt;&lt;br&gt;
Next, I needed to create a blob storage container specifically for the website’s documents, images, and other content. In the "Data storage" section of the storage account, I navigated to the "Containers" blade and added a new container named public. I configured this container to allow anonymous read access by setting the public access level to "Blob (anonymous read access for blobs only)". This setting is perfect for allowing users to view or download content without needing authentication.&lt;/p&gt;

&lt;p&gt;To test the setup, I uploaded a small file (like an image or text file) to the public container and grabbed the URL for the file. I pasted the URL into a new browser tab, and it displayed correctly—just what I needed for the public site.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 4: Configuring Soft Delete&lt;/strong&gt;&lt;br&gt;
One of my primary concerns was ensuring that website documents could be restored if accidentally deleted. To address this, I enabled soft delete for blobs. I went to the "Overview" blade of the storage account, located the "Blob service" section under "Properties," and enabled the "Blob soft delete" feature. I set the retention period to 21 days, which provides a decent buffer for accidental deletions.&lt;/p&gt;

&lt;p&gt;I also practiced using this feature by deleting a test file from my container and then restoring it. After toggling the "Show deleted blobs" option, I was able to locate the deleted file, use the ellipses to restore it, and confirm the restoration by refreshing the container view. It’s a straightforward process that adds an extra layer of safety for my data.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 5: Enabling Blob Versioning&lt;/strong&gt;&lt;br&gt;
Lastly, I enabled blob versioning to keep track of changes and maintain different versions of the documents. This is particularly useful for a public website where content may need frequent updates. Again, in the "Overview" blade of the storage account, I found the "Versioning" setting under the "Blob service" section and enabled it.&lt;/p&gt;

&lt;p&gt;To test versioning, I uploaded a new version of an existing file. As expected, the previous version was accessible through the "Show deleted blobs" feature, and I could easily manage different versions.&lt;/p&gt;

&lt;p&gt;Key Takeaways&lt;br&gt;
Setting up this highly available Azure storage account with public access and blob management features was a valuable exercise in understanding Azure’s storage capabilities. The configuration steps were straightforward, but the impact on data management and accessibility is significant. By leveraging RA-GRS, anonymous access, soft delete, and versioning, I created a robust storage solution that meets the needs of a public-facing application while ensuring data availability and recoverability.&lt;/p&gt;

</description>
      <category>azure</category>
      <category>microsoft</category>
    </item>
    <item>
      <title>Setting Up a Simple Azure Storage Account for Prototyping and Training</title>
      <dc:creator>Ayodeji Adesola</dc:creator>
      <pubDate>Mon, 09 Sep 2024 07:56:23 +0000</pubDate>
      <link>https://dev.to/theprotonguy/setting-up-a-simple-azure-storage-account-for-prototyping-and-training-2fb2</link>
      <guid>https://dev.to/theprotonguy/setting-up-a-simple-azure-storage-account-for-prototyping-and-training-2fb2</guid>
      <description>&lt;p&gt;Recently, I worked on a project where the goal was to prototype different storage scenarios and train new personnel in Azure. The data wasn’t critical, so there was no need for backups or complex recovery options if it got overwritten or removed. My task was to set up a simple and flexible storage configuration that could be easily adjusted. Here's a quick rundown of what I did and the steps I followed.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 1: Creating a Resource Group&lt;/strong&gt;&lt;br&gt;
To start, I needed a resource group to keep everything organized:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I went to the Azure portal and searched for Resource groups.&lt;/li&gt;
&lt;li&gt;Then, I clicked on + Create to start the process.&lt;/li&gt;
&lt;li&gt;I gave my resource group a name, something simple like theprotonguy, to easily identify it.&lt;/li&gt;
&lt;li&gt;After selecting a region (which I planned to use consistently throughout the project), I hit Review and create.&lt;/li&gt;
&lt;li&gt;Finally, I clicked Create to deploy the resource group. This step ensures all my project resources stay neatly contained.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Step 2: Creating a Storage Account&lt;/strong&gt;&lt;br&gt;
With the resource group ready, the next thing on my list was setting up a storage account:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;In the Azure portal, I searched for Storage accounts and selected + Create.&lt;/li&gt;
&lt;li&gt;I made sure to choose the resource group I just created.&lt;/li&gt;
&lt;li&gt;For the storage account name, I needed something unique across Azure, so I went with a distinctive name like teststorageaccount.&lt;/li&gt;
&lt;li&gt;I set the performance tier to Standard since high performance wasn’t a priority for this prototype.&lt;/li&gt;
&lt;li&gt;After reviewing everything, I clicked Create and waited for the deployment to finish. Once done, I clicked Go to resource to jump straight into the configuration.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Step 3: Configuring Basic Settings in the Storage Account&lt;/strong&gt;&lt;br&gt;
Now came the fun part—tweaking some basic settings to match the project's needs.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Configuring Redundancy&lt;/strong&gt;&lt;br&gt;
Since this was all about keeping costs low and we didn’t need high availability, I chose the simplest redundancy option:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I navigated to the Redundancy section under Data management in the storage account.&lt;/li&gt;
&lt;li&gt;Here, I selected Locally-redundant storage (LRS), which stores data within a single location, minimizing costs.&lt;/li&gt;
&lt;li&gt;I hit Save to lock in the changes and confirmed everything looked good by refreshing the page.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Enforcing Secure Transfer&lt;/strong&gt;&lt;br&gt;
Security is always a priority, even for training scenarios:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Under Configuration in the Settings section, I made sure that Secure transfer required was set to Enabled.&lt;/li&gt;
&lt;li&gt;This ensures that all data transferred to and from the storage account uses secure connections, which adds a layer of protection.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Setting the Minimum TLS Version&lt;/strong&gt;&lt;br&gt;
To keep up with best practices, I adjusted the TLS settings:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Still in the Configuration section, I set the Minimal TLS version to 1.2. This step ensures that all connections meet modern security standards.&lt;/li&gt;
&lt;li&gt;As usual, I saved these settings before moving on.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Disabling Shared Key Access&lt;/strong&gt;&lt;br&gt;
To prevent unauthorized access while the storage was idle, I disabled shared key access:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;In the same Configuration area, I found Allow storage account key access and set it to Disabled.&lt;/li&gt;
&lt;li&gt;After saving, this ensured that no one could access the account using shared keys, keeping it secure until needed.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Allowing Public Access from All Networks&lt;/strong&gt;&lt;br&gt;
Lastly, I adjusted the networking settings to ensure the storage account was easily accessible for testing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Under the Networking blade in Security + networking, I set Public network access to Enabled from all networks.&lt;/li&gt;
&lt;li&gt;After saving these changes, the storage account was ready for any network to connect, making it perfect for training and prototyping.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Overall, this was a straightforward setup designed for ease of use and low cost, ideal for scenarios where the data’s not critical. It was a great hands-on way to get familiar with Azure's storage configurations while keeping things simple and flexible. If you're looking to set up something similar or have questions, feel free to ask in the comments!&lt;/p&gt;

</description>
      <category>azure</category>
      <category>programming</category>
    </item>
    <item>
      <title>Key Concepts in Cloud Engineering</title>
      <dc:creator>Ayodeji Adesola</dc:creator>
      <pubDate>Sun, 08 Sep 2024 20:03:59 +0000</pubDate>
      <link>https://dev.to/theprotonguy/key-concepts-in-cloud-engineering-2jk5</link>
      <guid>https://dev.to/theprotonguy/key-concepts-in-cloud-engineering-2jk5</guid>
      <description>&lt;p&gt;Cloud engineering has transformed how businesses operate by offering scalable, flexible, and reliable solutions that can be accessed globally. In this post, we will explore some fundamental concepts in cloud engineering: Virtualization, Scalability, Agility, High Availability, Fault Tolerance, Global Reach, and the difference between Elasticity and Scalability.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;What is Virtualization?&lt;/strong&gt;&lt;br&gt;
Virtualization is a technology that allows you to create multiple simulated environments or virtual resources from a single physical hardware system. It abstracts the hardware of a single computer (such as a server) into multiple virtual machines (VMs) that can run different operating systems and applications independently from each other. Virtualization maximizes the use of resources by allowing multiple workloads to share the same hardware, reduces costs, and improves efficiency. It is the foundation of cloud computing, enabling the delivery of scalable and on-demand IT resources.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Scalability&lt;/strong&gt;&lt;br&gt;
Scalability refers to the ability of a system, network, or process to handle an increasing amount of work, or its potential to accommodate growth. In the context of cloud computing, scalability means that a cloud service can expand or reduce its resources and capacity to match the demand. For example, if your website experiences a sudden surge in traffic, a scalable cloud service can automatically add more computing power to manage the increased load, ensuring a smooth user experience without manual intervention.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Agility&lt;/strong&gt;&lt;br&gt;
Agility in cloud computing refers to the ability to rapidly develop, test, and deploy applications. It allows businesses to quickly respond to changes in the market or customer needs by providing the tools and environments necessary for rapid development and innovation. Agility is a critical advantage of cloud computing because it reduces the time it takes to bring new products or features to market, helping businesses stay competitive.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;High Availability&lt;/strong&gt;&lt;br&gt;
High Availability (HA) refers to the ability of a system or service to operate continuously without interruption for a desired period. It is achieved through redundant components and failover strategies that ensure service continuity even if some components fail. For instance, if a server in a cloud environment goes down, another server can take over, keeping the application running. High Availability is crucial for mission-critical applications that require maximum uptime and reliability.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Fault Tolerance&lt;/strong&gt;&lt;br&gt;
Fault Tolerance is the capability of a system to continue functioning correctly even when part of the system fails. It involves designing systems in a way that they can detect failures and automatically recover from them without affecting the end-user experience. Fault-tolerant systems use redundancy, such as having multiple servers or data replication, to ensure that the system can withstand component failures and still maintain its operations.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Global Reach&lt;/strong&gt;&lt;br&gt;
Global Reach refers to the ability of cloud services to be accessed from anywhere in the world, providing a consistent and reliable experience to users regardless of their geographic location. Cloud providers have data centers distributed across various regions and continents, allowing businesses to deploy their applications closer to their customers. This reduces latency and improves performance, making services more accessible and efficient for a global audience.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;What is the Difference Between Elasticity and Scalability?&lt;/strong&gt;&lt;br&gt;
Scalability and Elasticity are often used interchangeably but have distinct meanings:&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Scalability is the ability of a system to grow in capacity to meet increased demand by adding resources like more servers or storage. Scalability can be achieved vertically (adding more power to an existing machine) or horizontally (adding more machines to the pool).&lt;/p&gt;

&lt;p&gt;Elasticity, on the other hand, refers to the system’s ability to automatically adjust resources up or down based on the current workload. Elasticity is more dynamic and involves scaling both ways — expanding when demand spikes and shrinking when demand decreases, thus optimizing costs by using only the necessary resources at any given time.&lt;/p&gt;

&lt;p&gt;In essence, scalability is about being able to grow, while elasticity is about the ability to adjust dynamically to changes in demand.&lt;/p&gt;

</description>
      <category>cloud</category>
      <category>serverless</category>
      <category>azure</category>
    </item>
    <item>
      <title>Deploy Django Web App with SSL on VPS using Nginx &amp; Gunicorn</title>
      <dc:creator>Ayodeji Adesola</dc:creator>
      <pubDate>Sat, 04 May 2024 12:30:59 +0000</pubDate>
      <link>https://dev.to/theprotonguy/deploy-django-web-app-with-ssl-on-vps-using-nginx-gunicorn-mhl</link>
      <guid>https://dev.to/theprotonguy/deploy-django-web-app-with-ssl-on-vps-using-nginx-gunicorn-mhl</guid>
      <description>&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%2Fyqhtxq9ushds5o8ie43i.jpg" 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%2Fyqhtxq9ushds5o8ie43i.jpg" alt="Image description" width="800" height="450"&gt;&lt;/a&gt;&lt;br&gt;
Have you ever wanted to deploy your Django web application on a Virtual Private Server (VPS) with SSL encryption for secure communication? In this tutorial, we’ll walk through each step, from setting up prerequisites to configuring Nginx and Gunicorn, and finally securing your site with Let’s Encrypt SSL certificates.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prerequisites&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;Before we dive in, let’s ensure we have all the necessary tools and configurations in place.&lt;/p&gt;

&lt;p&gt;First, we’ll need to create a requirements.txt file containing all the Python packages used in our project. We can easily generate this file using the pip freeze command.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;pip freeze &amp;gt; requirements.txt&lt;/code&gt;&lt;br&gt;
Next, we’ll set up static files using Whitenoise, a handy Django middleware for serving static files efficiently.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;pip install whitenoise&lt;/code&gt;&lt;br&gt;
Once installed, we’ll integrate Whitenoise into our Django project by adding it to the middleware list and configuring static file settings.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# settings.py
MIDDLEWARE = [
    ...
    "whitenoise.middleware.WhiteNoiseMiddleware",
    ...
]
STATIC_URL = '/static/'
STATIC_ROOT = BASE_DIR / "staticfiles"
STATICFILES_DIRS = [
    os.path.join(BASE_DIR, 'static'),
]
STATICFILES_STORAGE = "whitenoise.storage.CompressedManifestStaticFilesStorage"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;With static files set up, let’s move on to deploying our project on a VPS.&lt;/p&gt;

&lt;h2&gt;
  
  
  Deploying on VPS:
&lt;/h2&gt;

&lt;p&gt;SSH into Your Server: First, SSH into your VPS by running:&lt;br&gt;
&lt;code&gt;ssh username@server_ip_address&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Update &amp;amp; Upgrade Server:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;sudo apt-get update&lt;br&gt;
sudo apt-get upgrade&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Install Python &amp;amp; Pip:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;&lt;br&gt;
sudo apt install python3&lt;br&gt;
sudo apt install python3-pip&lt;br&gt;
&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create &amp;amp; Activate Virtual Environment:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;virtualenv /opt/myproject&lt;br&gt;
source /opt/myproject/bin/activate&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Clone Repository onto server:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;cd /opt/myproject&lt;br&gt;
mkdir myproject&lt;br&gt;
cd myproject&lt;br&gt;
git clone repo-url&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Install Requirements (if any):&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;cd repo-name&lt;br&gt;
pip install -r requirements.txt&lt;br&gt;
pip install gunicorn&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Nginx Configuration:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Install Nginx and configure it to serve your Django app:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;sudo apt install nginx&lt;br&gt;
sudo nano /etc/nginx/sites-available/myproject&lt;/code&gt;&lt;br&gt;
Add the following configuration:&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 yourip;

    access_log /var/log/nginx/website-name.log;

    location /static/ {
        alias /opt/myproject/myproject/path-to-static-files/;
    }

    location / {
        proxy_pass http://127.0.0.1:8000;
        proxy_set_header X-Forwarded-Host $server_name;
        proxy_set_header X-Real-IP $remote_addr;
        add_header P3P 'CP="ALLDSP COR PSAa PSDa OURNOR ONL UNI COM NAV"';
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Set up a symbolic link and restart Nginx:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;cd /etc/nginx/sites-enabled&lt;br&gt;
sudo ln -s ../sites-available/myproject&lt;br&gt;
sudo service nginx restart&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Testing Configuration:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Test your Nginx configuration and adjust the firewall settings:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;sudo nginx -t&lt;br&gt;
sudo ufw allow 8000&lt;br&gt;
sudo service nginx restart&lt;/code&gt;&lt;br&gt;
Now, run Gunicorn and visit your project on your server’s IP address:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;gunicorn --bind 0.0.0.0:8000 project_name.wsgi&lt;/code&gt;&lt;br&gt;
With your Django app successfully deployed on your VPS, you’re one step closer to making it accessible to the world. But wait, there’s more!&lt;/p&gt;

&lt;h2&gt;
  
  
  Connecting a Domain:
&lt;/h2&gt;

&lt;p&gt;To connect your project to a custom domain, follow these steps:&lt;/p&gt;

&lt;p&gt;Open your domain registrar and navigate to the DNS settings for your domain.&lt;br&gt;
Add an A record with the name “@” pointing to your server’s IP address.&lt;br&gt;
Update your Nginx configuration to include your domain name.&lt;br&gt;
Restart Nginx and wait for DNS changes to propagate.&lt;/p&gt;

&lt;h2&gt;
  
  
  Securing with SSL:
&lt;/h2&gt;

&lt;p&gt;Installing SSL Certificates with Let’s Encrypt:&lt;/p&gt;

&lt;p&gt;Securing your website with SSL certificates is crucial for ensuring encrypted communication between your server and your users’ browsers. Let’s Encrypt provides free SSL certificates, making it accessible for everyone to enable HTTPS on their websites.&lt;/p&gt;

&lt;p&gt;Here’s how you can install SSL certificates on your VPS using Let’s Encrypt:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Install Certbot:
&lt;code&gt;sudo apt install certbot&lt;/code&gt;
&lt;code&gt;sudo apt install python3-certbot-nginx&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Obtain SSL Certificates:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Run Certbot with the --nginx option and specify your domain name(s) to obtain SSL certificates. Replace your_domain.com with your actual domain name.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;sudo certbot --nginx -d your_domain.com&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Verify Configuration:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;sudo nginx -t&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Reload Nginx:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;code&gt;sudo systemctl reload nginx&lt;/code&gt;&lt;br&gt;
By following these steps, you’ll have successfully installed SSL certificates on your VPS using Let’s Encrypt, enabling secure HTTPS connections for your Django web application.&lt;/p&gt;

&lt;p&gt;Background Process with Gunicorn:&lt;/p&gt;

&lt;p&gt;Additionally, if you want to run Gunicorn in the background to keep your Django application running even after you log out of your SSH session, you can use the nohup command followed by &amp;amp; to run Gunicorn as a background process. This ensures that your application remains accessible even when you're not actively managing it.&lt;/p&gt;

&lt;p&gt;Here’s how you can run Gunicorn in the background:&lt;/p&gt;

&lt;p&gt;Run Gunicorn:&lt;br&gt;
Navigate to your Django project directory and run Gunicorn with the appropriate bind address and port.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;cd /opt/myproject/myproject/repo-name&lt;br&gt;
nohup gunicorn --bind 0.0.0.0:8000 project_name.wsgi &amp;amp;&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Check Process Status:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;To verify that Gunicorn is running in the background, you can use the ps command to list all processes and grep for gunicorn.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;ps aux | grep gunicorn&lt;/code&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Stop Gunicorn Process:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If you ever need to stop the Gunicorn process running in the background, you can use the pkill command followed by gunicorn.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;pkill gunicorn&lt;/code&gt;&lt;br&gt;
Congratulations! Your Django web app is now deployed on a VPS with SSL encryption, ready to handle secure connections from users across the globe.&lt;/p&gt;

&lt;p&gt;Conclusion:&lt;/p&gt;

&lt;p&gt;In this tutorial, we’ve covered the entire deployment process, from setting up prerequisites to securing your site with SSL certificates. By following these steps, you can confidently deploy your Django projects on a VPS and provide a secure and reliable experience to your users.&lt;/p&gt;

&lt;p&gt;Happy deploying!&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
