CAUSE
By default, HSPcomplete Store is located inside /var/opt/hspc-frontend directory and HSPcomplete Frontend is configured to use files from this location by default. Sometimes, when default Store files are customized, it is required to use another location on filesystem for Store files as files under /var/opt/hspc-frontend directory will be overwritten during HSPcomplete upgrades. The article describes how to change location of HSPcomplete Store to /var/opt/store directory.RESOLUTION
Please use the following steps to change location of HSPcomplete Store from /var/opt/hspc-frontend to /var/opt/store/ :- Copy store files to /var/opt/store/:
# cd /var/opt/
# cp -a hspc-frontend/ store/ - Adjust HSPcomplete Frontend configuration file /etc/hspcd/conf/hspc_frontend.conf with replacing the following line in VirtualHost sections for _default_:80 and _default_:443: with the following line:
Alias /hspc/ /var/opt/hspc-frontend/vendor/1/Alias /store/ /var/opt/store/ - Adjust /etc/hspcd/conf/hspc_rewrite.conf configuration file in the following way:
- Comment the following line
RewriteRule ^(/hspc)?/?$ /hspc/index.php [L,R] - and add the following line:
RewriteRule ^(/store)?/?$ /store/index.php [L,R]
- Comment the following line
- Adjust /etc/hspcd/conf/hspc_alias.conf configuration file with commenting the following line:
Alias /store/ /var/opt/hspc-commerce-manager/www_store/ - Adjust /var/opt/hspc-data/CM/reseller_x.conf.src file in the following way:
- Remove the following line:
Alias /hspc/ /var/opt/hspc-frontend/vendor/@@VENDORID@@/ - Add the following line:
Alias /store/ /var/opt/hspc-frontend/vendor/@@VENDORID@@/
- Remove the following line:
- Adjust /var/opt/store/includes/settings.ini file with setting HTTP_ROOT variable to /store/:
HTTP_ROOT = /store/ - Reload HSPcomplete Frontend to apply changes and complete the reconfiguration:
# /etc/init.d/httpd reload
Additional information
Please do not forget to merge changes from default store location /var/opt/hspc-frontend into customized Store location (/var/opt/store in this example) after every HSPcomplete upgrade procedure.Keywords: store, change store, move store, customize frontend