CS-Cart is a versatile and robust eCommerce platform designed to facilitate the creation of your own online store effortlessly. Developed in PHP and using MariaDB for data storage, it offers an intuitive web interface to manage product inventories efficiently. While CS-Cart doesn’t offer a free version, a 30-day trial is available to explore its broad array of features such as multi-store capabilities, integrated SEO, a theme editor, various payment systems, and more.
This guide will walk you through the process of installing CS-Cart on an Ubuntu 18.04 server.
Prerequisites
- An Ubuntu 18.04 server.
- Root access to the server.
Getting Started
To begin, update your system to the latest version by executing the following commands:
apt-get update -y apt-get upgrade -y
After updating, reboot your server to apply the changes.
Install LAMP Stack
Since CS-Cart requires a web server environment, installing Apache, MariaDB, PHP, and additional PHP modules is necessary. Execute the following command to set up the LAMP stack:
apt-get install apache2 mariadb-server php7.2 libapache2-mod-php7.2 php7.2-common php7.2-sqlite3 php7.2-curl php7.2-intl php7.2-mbstring php7.2-xmlrpc php7.2-mysql php7.2-gd php7.2-xml php7.2-cli php7.2-zip php7.2-soap unzip -y
After the installation completes, open php.ini
and adjust some settings:
nano /etc/php/7.2/apache2/php.ini
Modify these lines:
memory_limit = 256M upload_max_filesize = 150M max_execution_time = 360 date.timezone = Asia/Kolkata
Save your changes and restart Apache and MariaDB, also making sure they’re set to start on boot:
systemctl restart apache2 systemctl start mariadb systemctl enable apache2 systemctl enable mariadb
Secure MariaDB
MariaDB requires hardening for security. Execute the following:
mysql_secure_installation
Follow these prompts to enhance security:
Enter current password for root (enter for none): Set root password? [Y/n]: N Remove anonymous users? [Y/n]: Y Disallow root login remotely? [Y/n]: Y Remove test database and access to it? [Y/n]: Y Reload privilege tables now? [Y/n]: Y
Next, log into the MariaDB shell to create a database and user for CS-Cart:
mysql -u root -p
Set up the database and user with these commands:
MariaDB [(none)]> CREATE DATABASE cscartdb; MariaDB [(none)]> CREATE USER 'cscart'@'localhost' IDENTIFIED BY 'password';
Grant the necessary privileges:
MariaDB [(none)]> GRANT ALL PRIVILEGES ON cscartdb.* TO 'cscart'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION;
Flush the privileges and exit:
MariaDB [(none)]> FLUSH PRIVILEGES; MariaDB [(none)]> EXIT;
Install CS-Cart
Download the latest CS-Cart version from its official site. Once downloaded, unzip it:
mkdir /var/www/html/cscart unzip cscart_v4.9.3.SP1.zip -d /var/www/html/cscart
Ensure appropriate permissions:
chown -R www-data:www-data /var/www/html/cscart/ chmod -R 755 /var/www/html/cscart/
Configure Apache for CS-Cart
Create an Apache virtual host configuration file:
nano /etc/apache2/sites-available/cscart.conf
Input these settings:
<VirtualHost *:80> ServerAdmin admin@example.com ServerName example.com DocumentRoot /var/www/html/cscart/ <Directory /var/www/html/cscart/> Options FollowSymlinks AllowOverride All Allow from all </Directory> ErrorLog /var/log/apache2/cscart_error.log CustomLog /var/log/apache2/cscartcart_access.log combined </VirtualHost>
Enable the site and Apache rewrite module, then restart Apache:
a2ensite cscart.conf a2enmod rewrite systemctl restart apache2
Check the Apache service status:
systemctl status apache2
You should see the server actively running output.
Access CS-Cart Web Interface
With CS-Cart installed and configured, access its web interface using your browser at http://example.com
. Follow the installation steps:
Accept the license and complete the setup:
Fill in your database and admin information:
Finalize your setup and explore the CS-Cart dashboard:
Access the administration panel to start managing your store:
Congratulations! You’ve successfully installed and configured CS-Cart on your Ubuntu 18.04 server, ready to create your eCommerce store.
FAQ
What is CS-Cart?
CS-Cart is a robust eCommerce platform allowing users to build and manage online stores of any size, offering features like multi-store capabilities, integrated SEO, and various themes and payment systems.
Is there a free version of CS-Cart?
CS-Cart does not have a free version; however, a 30-day trial period is available for testing all its features.
Can I customize my CS-Cart store?
Yes, CS-Cart offers a theme and layout editor, allowing for significant customization to fit your branding and store’s unique needs.
Do I need prior experience with web servers to install CS-Cart?
While prior experience can be helpful, this guide provides detailed steps, making it accessible for users new to server management and web hosting.