Skip to content

CS-Cart development environment based on Docker containers

License

Notifications You must be signed in to change notification settings

searchanise/cs-cart-docker

 
 

Repository files navigation

CS-Cart Development Environment

Docker-based development environment:

  • PHP versions: 7.3, 7.4, 8.0, 8.1
  • MySQL 5.7 database server.
  • Nginx web server.

Installation

  1. Follow Standard Docker application installation instructions, REPOSITORY_URL=[email protected]:searchanise/cs-cart-docker.git
  2. (Optional) For speed up in the future, you can disable installation when a cs-cart Docker container starts via setting an env variable in a file .env to value:
CSCART_INSTALL="no"

When you want to reinstall the cs-cart, don't forget to set it to a "yes" back 3. Add new hosts files to /etc/hosts:

127.0.0.1 localhost php7.3.cs-cart.local php7.4.cs-cart.local php8.0.cs-cart.local php8.1.cs-cart.local
  1. Add via the storefronts admin panel new storefronts with the following URLs:
php7.3.cs-cart.local:8100
php8.0.cs-cart.local:8100
php8.1.cs-cart.local:8100
  1. After installation, CS-Cart is available at these links:

Usage

First, enter to admin panel by a path /admin.php.

Licences

You can enter here a license for disabling a trial subscription: Test CS-Cart licenses

Switch a CS-Cart product edition

For switch:

  1. Change variable CSCART_PRODUCT_EDITION inside .env file to
    1. ULTIMATE - for ultimate edition
    2. MULTIVENDOR - for multivendor edition
  2. Clear database and recreate containers:
docker-compose down
sudo rm -Rf app/db/*
docker-compose up -d

Switch a CS-Cart version

cd app/www
git checkout $REVISION

MySQL connection

You can connect MySQL Client to a database via settings from the "SETTING MYSQL" section of file .env.

Development

Sending e-mails

PHP containers do not send actual e-mails when using the mail() function.

All sent emails will be caught and stored in the app/log/sendmail directory.

Enabling xDebug for PHP containers

xDebug is already configured.

You can read about configuring PHPStorm to work with Docker and xDebug 3 in the Debugging PHP article.

Information

Directories structure

See standard Docker application structure

Also, the application has additional directories:

  • app
    • db - database data files
    • log - mail logs
    • www - CS-Cart source files

About

CS-Cart development environment based on Docker containers

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 95.8%
  • Dockerfile 4.2%