How To Install AbanteCart On Ubuntu Server

Have a Linux-powered website and looking to set up a shopping platform for it? If so, do yourself a favor and check out AbanteCart. It’s an open source, free eCommerce platform that users can manage and customize on their own eCommerce platform. Before you can install AbanteCart on Ubuntu server, ensure you have LAMP on it.

Install LAMP

Usually, a LAMP stack is easy to get working on Ubuntu server, as users are able to check a box and load it up during installation. However, if, for some reason you chose to avoid setting this up, install it now with the following commands.

First, run the update tool. Doing this will ensure that the Ubuntu server has the latest packages.

sudo apt update
sudo apt upgrade -y

After upgrading, you’ll need to install the Tasksel tool. Using this tool, rather than the traditional Ubuntu package manager is much faster, as you won’t need to specify every single package by hand.

sudo apt install tasksel

Next, use the Tasksel tool to install a LAMP Stack.

Note: during the LAMP installation process, a prompt will appear that asks the user to set a new SQL root password. Be sure to use a memorable, secure password.

RECOMMENDED FOR YOU

Install AbanteCar

When the LAMP installation is complete, it’s safe to install AbanteCart on Ubuntu server. Using the wget tool, download the latest release of the software:

sudo -s
cd /tmp

wget https://github.com/abantecart/abantecart-src/archive/master.zip

Create a new AbanteCart folder inside of /www/html/ with mkdir.

mkdir -p /var/www/html/abantecart

Extract the master.zip archive using the unzip command into the new folder.

unzip master.zip -d /var/www/html/abantecart

Use the CD command to move into /var/www/html/abantecart/public_html.

cd /var/www/html/abantecart/public_html

Delete all unnecessary files using the rm command.

rm -rf tests
rm *.txt
rm *.md

Move the contents of public_html into /var/www/html/abantecart

mv * ..

Configure AbanteCart

With all the files are in place, it’s time to start configuring AbanteCart on Ubuntu server. The first step is to give the Apache web server ownership of the AbanteCart directory. Without granting ownership to Apache, AbanteCart will not run. Using the chown command, give Apache rights to the folder.

chown -R www-data: /var/www/html/abantecart

Enter /var/www/html/abantecart using CD.

cd /var/www/html/abantecart

Thanks to Chown, the web server has access to /var/www/html/abantecart. However, since the permissions aren’t set right, the software still will not run correctly. To fix this, run the chmod command.

SQL Setup

The AbanteCart software uses MySQL to handle its database needs. As a result, you’ll need to create a new SQL database. In the terminal, enter the SQL command interface with the Root user.

mysql -u root -p

In the SQL prompt, create a new database for AbanteCart to use.

CREATE DATABASE abantecart;

Once the database is set up, create a new user and grant it the appropriate permissions.

Note: change ‘securepassword’ with a secure password.

GRANT ALL PRIVILEGES on abantecart.* to 'abante_admin'@'localhost' identified by 'securepassword';

AbanteCart now has an SQL user and database to interact with, which means our work in MySQL is done. To exit the tool, do the following:

FLUSH PRIVILEGES;
QUIT

Apache Configuration

Setting up AbanteCart on Apache requires minor configuration. Specifically, you’ll need to let Apache know that the AbanteCart software is a site and should be loaded. In the terminal, use the Nano editor to create a new “sites available” file.

Save the file in Nano by pressing the Ctrl + O key combination. Exit the editor with Ctrl + X.

After exiting Nano, enable the new site with:

sudo a2ensite abantecart

Setup AbanteCart

Configuring the AbanteCart app, like most web tools requires a web browser. To access the tool, open up a new tab in your browser and paste the following URL into the location bar:

http://server-local-ip-address/abantecart

Not sure of your server’s local IP address? Try using the ip addr command in terminal:

ip addr show | grep 192.168.1

Running ip addr show in combination with grep will filter out any unnecessary information and isolate the IPv4 local IP address. When the web UI loads up, you’ll be greeted with a sleek setup utility. Follow the instructions on screen to get everything setup.