How to install Opencart – 3.0.2 on CentOS – 7

To install Opencart 3.0.2 on CentOS 7

Opencart is free and open source e-commerce platform for online shopping application and it provides a professional and reliable foundation from which we can build a successful online store. This foundation to use, to shop a variety of users and ranging from seasoned web developers looking for a user-friendly interface to using the shop owners will just launch their online business.

Prerequisites

  • Install LAMP(Apache, MariaDB, php5.6)

In MariaDB (create database and user and give privileges to that user )

  • Php installation with required following modules
rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
yum install php56w php56w-opcache php56w-mysql php56w-curl php56w-xml  php56w-mcrypt php56w-gd php56w-mysqlnd

Installing Opencart 3.0.2

You can download the opencart package from the terminal using the following command.

[root@linuxhelp1 ~]# cd Downloads/
[root@linuxhelp1 Downloads]# wget https://github.com/opencart/opencart/releases/download/3.0.2.0/3.0.2.0-OpenCart.zip
--2018-04-16 03:07:22--  https://github.com/opencart/opencart/releases/download/3.0.2.0/3.0.2.0-OpenCart.zip
Resolving github.com (github.com)... 192.30.253.112, 192.30.253.113
Connecting to github.com (github.com)|192.30.253.112|:443... connected.
.
.
HTTP request sent, awaiting response... 200 OK
Length: 16544198 (16M) [application/octet-stream]
Saving to: ‘ 3.0.2.0-OpenCart.zip’ 

100%[============================================================> ] 16,544,198   836KB/s   in 53s    

2018-04-16 03:08:17 (306 KB/s) - ‘ 3.0.2.0-OpenCart.zip’  saved [16544198/16544198]

After downloading you need to Unzip the package.

[root@linuxhelp1 Downloads]# unzip 3.0.2.0-OpenCart.zip 
Archive:  3.0.2.0-OpenCart.zip
  inflating: build.xml               
  inflating: CHANGELOG.md            
  inflating: CHANGELOG_AUTO.md       
  inflating: composer.json           
  inflating: composer.lock
.
.
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatOauth.php  
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatPay.php  
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatPoi.php  
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatReceive.php  
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatScript.php  
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatService.php  
  inflating: upload/system/storage/vendor/zoujingli/wechat-php-sdk/Wechat/WechatUser.php

Now, move the unzipped directory into the following path.

[root@linuxhelp1 Downloads]# mv opencart /var/www/

Then, switch to the directory.

[root@linuxhelp1 Downloads]# cd /var/www/

next, you have to change the ownership and permission of the Opencart directory.

[root@linuxhelp1 www]# chown -R apache.apache opencart
[root@linuxhelp1 www]# chmod -R 775 opencart

After changing permission create the new virtual host configuration for accessing the Opencart application.

[root@linuxhelp1 www]# vim /etc/httpd/conf.d/opencart.conf

After creating the virtual host need to restart the httpd service.

[root@linuxhelp1 www]# systemctl restart httpd

Now you can further proceed the installation graphically from the browser by navigating to the following URL: http://local IP (or) domain name.

First, you need to accept the license terms to continue.

And then it will verify the server setup configuration. once the requirements are met you can click continue to proceed.

Next, you need to configure the database configuration as follows.

Now the installation setup is complete and to access opencart admin panel click on login as admin.

Now login with Admin user credential.

After successful login, you will see the admin dashboard of opencart.

Then you can choose the Admin user profile and click on your store option, and it will redirect to your site.

With this, the method to install Opencart 3.0.2 on CentOS 7 comes to an end.

Comment
markp
Dec 16 2019
Obviously an old post. It would really help, And save time, to add a date to the posts so people would know right away they don't need to bother reading certain post (because they're outdated, already).
Add a comment
FAQ
Q
while navigate in the browser it shows only blank page , please help me with this ?
A
Please check whether the PHP modules are installed properly or not.
Q
after installation it shows 404 not found while calling in browser ?
A
check the documentroot are correctly pointed in virtualhost .
Q
I have got forbidden error, so I need to help me with this ?
A
check the permission which is given for documentroot . Give the permission as apache user for document root .
Q
is there any alternative tool available ?
A
yeah, there is you can use PrestaShop,Magento,WooCommerce,Zen Cart
Q
While installing prestashop I got many error . Please help me with installation ?
A
follow this site : https://www.linuxhelp.com/how-to-install-prestashop-on-ubuntu-16-04/