Adobe Introduces Powerful Generative AI Tools in Photoshop
Artificial Intelligence

Adobe Introduces Powerful Generative AI Tools in Photoshop Beta

by Veronica
June 1, 2023
2

Adobe Photoshop beta AI will take your creativity to the...

Read more
Adobe Photoshop's Generative Fill Feature

Exploring the Power of Adobe Photoshop’s Generative Fill Feature

June 1, 2023
ChatGPT app

The Easiest Way to Download ChatGPT App Free

June 1, 2023
Nvidia Unveils Futuristic Gaming Experience at Computex 2023

Nvidia Unveils Futuristic Gaming Experience at Computex 2023, Blending Gaming and AI

May 29, 2023
NVIDIA and Microsoft Partner to Accelerate AI

NVIDIA and Microsoft Partner to Accelerate AI

May 25, 2023
ChatGPT Cheat sheet for Frontend Designer

Ultimate ChatGPT cheatsheet for frontend Designers

May 10, 2023
How to Use ChatGPT in Linux Terminal

How to Use ChatGPT in Linux Terminal

May 19, 2023
Stable Diffusion web UI

Stable Diffusion web UI: A Comprehensive Guide

May 30, 2023
Visual ChatGPT

Visual ChatGPT: The AI That Can Generate, Edit and Answer Questions About Images

May 26, 2023
How to use Autogpt in web browser

How to use AutoGPT in web browser

May 4, 2023
How to disable ChatGPT history

How to Disable ChatGPT History and Keep Your Conversations Private

May 13, 2023
Cloudbooklet
  • News
  • Artificial Intelligence
  • Linux
  • Google Cloud
  • AWS
No Result
View All Result
Cloudbooklet
  • News
  • Artificial Intelligence
  • Linux
  • Google Cloud
  • AWS
No Result
View All Result
Cloudbooklet
No Result
View All Result
Home Linux

Install nopCommerce on Ubuntu 20.04, MySQL, Nginx, SSL

by Cloudbooklet
May 23, 2023
in Linux, MySQL
Reading Time: 8 mins read
Install nopCommerce on Ubuntu 20.04 MySQL Nginx SSL
Share on FacebookShare on TwitterShare on WhatsAppShare on Telegram

nopCommerce is a free open-source e-commerce web application built with ASP.NET. It is a high performance application with multi-store, multi-vendor and a user-friendly web interface.

In this guide you are going to learn how to install nopCommerce in Ubuntu 20.04 with MySQL, Nginx and secure the setup with Let’sEncrypt SSL.

You might also like

Best PHP-FPM Configuration - Easy and Simple Calculation

Best PHP-FPM Configuration – Easy and Simple Calculation

June 1, 2023
Install WordPress with Docker Compose, Nginx, Apache with SSL

WordPress Deployment Made Easy: Docker Compose, Nginx, Apache, SSL Setup Guide

May 20, 2023

Prerequisites

  • A Ubuntu 20.04 server and user with sudo privileges.

1. Initial setup

Update all packages to the latest version available.

sudo apt update
sudo apt dist-upgrade -y

Install unzip package to extract nopCommerce source code.

sudo apt install unzip

2. Install MySQL

Install MySQL server for your database. We will install MySQL 8.

sudo apt install mysql-server mysql-client

Secure MySQL server.

sudo mysql_secure_installation

Follow the prompts one by one and setup new password for your root user.

Login to MySQL.

sudo mysql -u root -p

Enter the password you have configured earlier to login.

3. Create Database for nopCommerce

Create a new database and user for the nopCommerce application.

CREATE DATABASE nopcommerce_db /*\!40100 DEFAULT CHARACTER SET utf8mb4 */;

Create new user.

CREATE USER 'nopcommerce_user'@'localhost' IDENTIFIED BY 'secure_password';
GRANT ALL PRIVILEGES ON nopcommerce_db.* TO 'nopcommerce_user'@'localhost';
FLUSH PRIVILEGES;

Now you have MySQL installed and have new database with user.

4. Install ASP.NET

Download Microsoft package signing key and add it you the package repository.

Execute the following commands.

sudo wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
sudo rm packages-microsoft-prod.deb

Install ASP.NET runtime.

sudo apt update
sudo apt install apt-transport-https
sudo apt install aspnetcore-runtime-6.0

Verify the installation.

dotnet --list-runtimes

Output
Microsoft.AspNetCore.App 6.0.3 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 6.0.3 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

5. Install Nginx

Now we will install Nginx and configure it.

sudo apt install nginx

Once the installation is complete, we will delete the default server blocks and configure a new one for nopCommerce.

sudo rm -rf /etc/nginx/sites-available/default
sudo rm -rf /etc/nginx/sites-enabled/default

Configure Nginx for nopCommerce.

Create a new configuration file.

sudo nano /etc/nginx/sites-available/nopcommerce.conf

Paste the following to the file. We are using a proxy configuration to port 5000 on which nopCommerce runs.

server {
    listen 80;
    listen [::]:80;

    server_name domain.com www.domain.com;

    location / {
        proxy_pass         http://localhost:5000;
        proxy_http_version 1.1;
        proxy_set_header   Upgrade $http_upgrade;
        proxy_set_header   Connection keep-alive;
        proxy_set_header   Host $host;
        proxy_cache_bypass $http_upgrade;
        proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header   X-Forwarded-Proto $scheme;
    }
}

Hit CTRL+X followed by Y and ENTER to save and exit the file.

Enable the configuration by creating a symlink to sites-enabled directory.

sudo ln -s /etc/nginx/sites-available/nopcommerce.conf /etc/nginx/sites-enabled/nopcommerce.conf

Restart Nginx for the configuration to take effect.

sudo service nginx restart

6. Install nopCommerce

Navigate to your favorite directory to download latest nopCommerce source code for Linux from their official Git repository.

cd /var/www/html
sudo wget https://github.com/nopSolutions/nopCommerce/releases/download/release-4.50.1/nopCommerce_4.50.1_NoSource_linux_x64.zip

Extract the downloaded file.

sudo unzip nopCommerce_4.50.1_NoSource_linux_x64.zip

Remove the zip file.

sudo rm -rf nopCommerce_4.50.1_NoSource_linux_x64.zip

Configure permissions.

sudo chmod -R 755 /var/www/html
sudo chown -R www-data:www-data /var/www/html

7. Configure nopCommerce as a Service

Configure nopCommerce as a service so that it runs as a system service. It will be easier to manage.

Create a new service file.

sudo nano /etc/systemd/system/nopcommerce.service

Paste the following contents.

Unit]
Description=NopCommerce eCommerce application

[Service]
WorkingDirectory=/var/www/html/
ExecStart=/usr/bin/dotnet /var/www/html/Nop.Web.dll
Restart=always

# Auto restart nopCommerce in 10 seconds if .NET crashes
RestartSec=10
KillSignal=SIGINT
SyslogIdentifier=nopcommerce
User=www-data
Environment=ASPNETCORE_ENVIRONMENT=Production
Environment=DOTNET_PRINT_TELEMETRY_MESSAGE=false

[Install]
WantedBy=multi-user.target

Restart system daemon.

sudo systemctl daemon-reload

Enable nopCommerce to start at system boot.

sudo systemctl enable nopcommerce

Start nopCommerce.

sudo systemctl start nopcommerce

Check status using the following command.

sudo systemctl status nopcommerce
● nopcommerce.service - NopCommerce Ecommerce Application
     Loaded: loaded (/etc/systemd/system/nopcommerce.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2022-04-06 06:22:05 UTC; 2min 36s ago
   Main PID: 5149 (dotnet)
      Tasks: 20 (limit: 1151)
     Memory: 449.6M
     CGroup: /system.slice/nopcommerce.service
             └─5149 /usr/bin/dotnet /var/www/html/Nop.Web.dll

Now you have nopCommerce, MySQL, Nginx running.

8. Install Let’sEncrypt SSL

We can use Certbot to install free Let’s Encrypt SSL certificate for your domain.

sudo apt install python3-certbot-nginx

Execute the following command to install certificate and configure redirect to HTTPS automatically.

sudo certbot --nginx --redirect --agree-tos --no-eff-email -m [email protected] -d domain.com -d www.domain.com

Now you should receive SSL certificate and it will be configured automatically.

Setup auto renewal.

sudo certbot renew --dry-run

Now we have configured everything.

Check your domain on your browser, you will see the installation guide page.

Nopcommerce installation

For Server name under Database Information use localhost.

Fill all other appropriate values and click Install.

This will take some time and then your nopCommerce service will get started.

Once the installation is complete you will see your default homepage.

nopCommerce

Now you have a successful installation of nopCommerce with ASP.NET, MySQL, Nginx, Let’sEncrypt SSL.

Conclusion

Now you have learned how to install nopCommerce on Ubuntu 20.04 with Nginx, MySQL and SSL.

Thanks for your time. If you face any problem or any feedback, please leave a comment below.

Tags: ASP.NETMySQLNginxUbuntu 20.04
ShareTweetSendShare
Cloudbooklet

Cloudbooklet

Help us grow and support our blog! Your contribution can make a real difference in providing valuable content to our readers. Join us in our journey by supporting our blog today!
Buy me a Coffee

Related Posts

How to Install WordPress on Docker

How to Install WordPress on Docker for Windows, macOS, and Linux

May 20, 2023
How to install python on Ubuntu

How to Install Python on Ubuntu 22.04?

May 31, 2023
what's new in node.js 20

What’s new in Node.js 20?

April 23, 2023
AutoGPT in Linux

How to download and install Auto GPT in Linux

May 4, 2023

Comments 3

  1. Andre says:
    11 months ago

    Hi Ryan, I managed to get around that by installing an older version of MySQL (8.0.25), but there are posts on the nopCommerce forums about this issue. It has to do with the latest version of MySQL (8.0.29), but I couldn’t recompile the source code to get around it, so I opted to downgrade MySQL.

    Reply
  2. Ryan says:
    1 year ago

    It’s so sad it failed at the last step.

    Reply
  3. Ryan says:
    1 year ago

    I followed your instructions. Installation page was able to load. After clicking Install, following error message is shown:
    Setup failed: An exception was thrown while activating λ:FluentMigrator.Runner.IVersionLoader.

    What should I do?

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

I agree to the Terms & Conditions and Privacy Policy.

  • Trending
  • Comments
  • Latest
DragGAN The AI-Powered Image Editing Tool

DragGAN: The AI-Powered Image Editing Tool That Makes Editing Images Easy

May 30, 2023
DragGAN AI editing Tool Install and Use DragGAN Photo Editor

DragGAN AI editing Tool Install and Use DragGAN Photo Editor

May 27, 2023
Bard API key

Everything You Need to Know About Google’s Bard API Key

May 20, 2023
Install PHP 8.1 on Ubuntu

How to Install or Upgrade PHP 8.1 on Ubuntu 20.04

May 17, 2023
DragGAN The AI-Powered Image Editing Tool

DragGAN: The AI-Powered Image Editing Tool That Makes Editing Images Easy

79
Upgrade PHP version to PHP 7.4 on Ubuntu

Upgrade PHP version to PHP 7.4 on Ubuntu

28
Install Odoo 13 on Ubuntu 18.04 with Nginx - Google Cloud

Install Odoo 13 on Ubuntu 18.04 with Nginx – Google Cloud

25
Best Performance WordPress with Google Cloud CDN and Load Balancing

Best Performance WordPress with Google Cloud CDN and Load Balancing

23
Best PHP-FPM Configuration - Easy and Simple Calculation

Best PHP-FPM Configuration – Easy and Simple Calculation

June 1, 2023
ChatGPT Shared Links

ChatGPT Shared Links: A New Way to Share Your Conversations

June 1, 2023
Deepfake

Deepfake: The Rise of Synthetic Media

June 1, 2023
How to Setup SSH Keys on Ubuntu

How to Setup SSH Keys on Ubuntu 20.04

May 31, 2023

Popular Articles

  • DragGAN The AI-Powered Image Editing Tool

    DragGAN: The AI-Powered Image Editing Tool That Makes Editing Images Easy

    1515 shares
    Share 606 Tweet 379
  • DragGAN AI editing Tool Install and Use DragGAN Photo Editor

    397 shares
    Share 159 Tweet 99
  • Auto-Photoshop-Stable Diffusion-Plugin: A New Way to Create AI-Generated Images in Photoshop

    71 shares
    Share 28 Tweet 18
  • InternGPT: A New Way to Interact with ChatGPT

    56 shares
    Share 22 Tweet 14
  • Microsoft research Reveals GPT-4 AI Shows Promising Signs of Common Sense and Human-Like Reasoning

    99 shares
    Share 40 Tweet 25
Latest Technology Trends in Artificial Intelligence and Machine Learning with Cloudbooklet

Welcome to our technology blog, where we explore the latest advancements in the field of artificial intelligence (AI) and how they are revolutionizing cloud computing. In this blog, we dive into the powerful capabilities of cloud platforms like Google Cloud Platform (GCP), Amazon Web Services (AWS), and Microsoft Azure, and how they are accelerating the adoption and deployment of AI solutions across various industries. Join us on this exciting journey as we explore the endless possibilities of AI and cloud computing.

  • About
  • Contact
  • Disclaimer
  • Privacy Policy

Cloudbooklet © 2023 All rights reserved.

No Result
View All Result
  • News
  • Artificial Intelligence
  • Linux
  • Google Cloud
  • AWS

Cloudbooklet © 2023 All rights reserved.

This website uses cookies. By continuing to use this website you are giving consent to cookies being used. Visit our Privacy and Cookie Policy.