This repository contains examples of production and development environments for EspoCRM.
- Download the needed environment directory, ex.
php8.0-nginx-mysql
. - Inside the downloaded directory run the command:
docker-compose up -d
- Wait some time for deploying the containers.
- Download and extract EspoCRM files to the
html
directory. - Visit
http://localhost:8080
and install EspoCRM.
docker-compose up -d
docker-compose up -d --build "$@"
docker-compose restart
docker-compose down
docker-compose ps
docker-compose logs
Default connection information:
- Host Name:
espocrm-mysql
- Database Name:
ANY
- User:
root
- Password:
1
Default connection information:
- Host Name:
espocrm-mariadb
- Database Name:
ANY
- User:
root
- Password:
1
Default connection information:
- Host Name:
espocrm-postgres
- Database Name:
espocrm
- User:
espocrm
- Password:
espo_password
Edit the docker-compose.yml
:
espocrm-mysql:
.....
ports:
- 8033:3306
Edit the file config.inc.php
under the phpMyAdmin directory:
$i++;
$cfg['Servers'][$i]['verbose'] = 'Docker: espocrm-mysql';
$cfg['Servers'][$i]['host'] = '127.0.0.1';
$cfg['Servers'][$i]['port'] = 8033;
$cfg['Servers'][$i]['socket'] = '';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = '';
* * * * * /usr/bin/docker exec --user www-data -i espocrm-php /bin/bash -c "cd /var/www/html; php cron.php" > /dev/null 2>&1
Edit the docker-compose.yml
:
espocrm-websocket:
image: espocrm/espocrm
container_name: espocrm-websocket
volumes:
- ./html:/var/www/html
restart: always
entrypoint: php websocket.php
ports:
- 8081:8080
In your data/config.php
add:
'useWebSocket' => true,
'webSocketUrl' => 'ws://localhost:8081',
'webSocketZeroMQSubscriberDsn' => 'tcp://*:7777',
'webSocketZeroMQSubmissionDsn' => 'tcp://espocrm-websocket:7777',
Inside your directory with docker-composer.yml
file run the command:
sudo docker-compose down -v
Then:
sudo docker-compose up -d --build "$@"
/usr/bin/docker exec --user www-data phpunit --bootstrap vendor/autoload.php tests/unit
/usr/bin/docker exec --user www-data phpunit --bootstrap vendor/autoload.php tests/integration