espocrm / espocrm-docker Goto Github PK
View Code? Open in Web Editor NEWOfficial Docker Image for EspoCRM
Home Page: https://hub.docker.com/r/espocrm/espocrm
License: GNU Affero General Public License v3.0
Official Docker Image for EspoCRM
Home Page: https://hub.docker.com/r/espocrm/espocrm
License: GNU Affero General Public License v3.0
According to this conversation with Yuri I found out missing arm64 arch support I've tried to create own docker image for arm64 but I've stuck with PhantomJS missing binary, but problem has probably gone espocrm/espocrm#2538
I need arm64 need for dockerization of dev env
Hello,
After upgrading to 7.1.7 from 7.0.10, the espocrm-daemon it's in restarting loop with this error:
espocrm-daemon exited with code 0
After the update we get:
Attaching to espocrm, espocrm-daemon
espocrm | Run "upgrade" action.
espocrm | Start upgrading process from version 7.0.10.
espocrm | Upgrade process is finished. EspoCRM version is 7.1.7.
But the daemon it's in a restarting loop.
It's there a path to make the update to the latest version ?
Thank you.
Hello,
we are unable to upgrade from 8.1.4 to whatever version
It's an docker compose setup and it always says:
Run "upgrade" action.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4.
Start upgrading process from version 8.1.4
The MAX_UPGRADE_COUNT exceded. The upgrading process has been stopped.
that from 8.1.4 to 8.1.5, from 8.1.4. to 8.2.0 and so on.
What's the issue?
Thanks
【Add this line to the crontab file to run Espo Scheduled Jobs】:What does this note mean?
Is it for me to manually add [* * * * * cd /var/www/html; /usr/local/bin/php -f cron.php > /dev/null 2>&1] in the crontab of the operating system?
Or it has no other meaning, just an example。
Today we update the espocrm from 6.1.9 to 7.0.4 but the Scheduled Jobs don't work anymore.
All Scheduled Jobs don't work after the update.
Before update: 6.1.9
After update: 7.0.4
EspoCRM it's installed in docker container with external database
I need to add the cron in the container or it's bug ?
in logs /var/www/html/data/logs I can see this:
[2021-10-14 17:15:08] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:15:18] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:15:28] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:15:38] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:15:48] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:15:58] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:16:08] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:16:18] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:16:28] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:16:38] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:16:48] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:16:58] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:17:08] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:17:18] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:17:28] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:17:38] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:17:48] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:17:58] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:18:08] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:18:23] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:18:28] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:18:38] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:18:48] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:18:58] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:19:08] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:19:18] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:19:28] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
[2021-10-14 17:19:38] WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
It's a param. in the docker-compose or somewhere else?
Thank you.
Thanks for the official Docker repository. I wrap all our gitlab CI/CD around this repo as a git submodule. The only issue I ran into was the use of git:// when cloning php-zmq in the Docker build script when running behind a web proxy. I was able to get around this by replacing git:// with https:// in the deployment script after checkout.
Is your feature request related to a problem? Please describe.
I want to deploy EspoCRM in a local kubernetes cluster, but there is no official helm chart.
Describe the solution you'd like
This would be solved by providing an official helm chart.
Hi,
After updating espocrm from 7.0.4 to 7.0.7, we can't enable "Use Cache" in Settings.
I don't know if it was enable or disable before (on 7.0.4) but on 6.1.9 it was 100% enable use cache.
What we're using:
I get this error in logs:
[2021-10-20 14:45:56] ERROR: (500) Error while clearing cache; PUT /Settings/1; line: 132, file: /var/www/html/application/Espo/Core/DataManager.php [] []
[2021-10-20 14:46:04] WARNING: E_WARNING: unlink(data/cache/application/cronLastRunTime.php): Permission denied {"code":2,"message":"unlink(data/cache/application/cronLastRunTime.php): Permission denied","file":"/var/www/html/application/E
spo/Core/Utils/File/Manager.php","line":755} []
[2021-10-20 14:46:04] ERROR: (500) Error while clearing cache; PUT /Settings/1; line: 132, file: /var/www/html/application/Espo/Core/DataManager.php [] []
[2021-10-20 14:47:54] WARNING: E_WARNING: unlink(data/cache/application/cronLastRunTime.php): Permission denied {"code":2,"message":"unlink(data/cache/application/cronLastRunTime.php): Permission denied","file":"/var/www/html/application/E
spo/Core/Utils/File/Manager.php","line":755} []
[2021-10-20 14:47:54] ERROR: (500) Error while clearing cache; PUT /Settings/1; line: 132, file: /var/www/html/application/Espo/Core/DataManager.php [] []
[2021-10-20 14:50:14] WARNING: E_WARNING: unlink(data/cache/application/cronLastRunTime.php): Permission denied {"code":2,"message":"unlink(data/cache/application/cronLastRunTime.php): Permission denied","file":"/var/www/html/application/E
spo/Core/Utils/File/Manager.php","line":755} []
I tried to chown data/cache/application/cronLastRunTime.php from root to apache but it'll overwrite again to root.
Thank you.
I've set up Espo pretty almost exactly like you in your example docker-compose.
Unfortunatly, I can't get the cronjob to work. Here's the part of my docker compose
# CRM
crm-db:
image: mariadb
command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW
restart: always
volumes:
- ./data/crm/db:/var/lib/mysql
env_file:
- crm.env
networks:
- crm
crm:
build: ./crm
restart: always
volumes:
- ./data/crm/system:/var/www/html
depends_on:
- crm-db
networks:
- crm
crm-cron:
build: ./crm
restart: always
volumes:
- ./data/crm/system:/var/www/html
depends_on:
- crm
networks:
- crm
entrypoint: docker-cron.sh
I'm using the Dockerfile and docker-entrypoint.sh, docker-cron.sh from the apache folder.
As there are different settings for the local and production environment, there are more configs publishing the port or hiding behind a reverse proxy.
I'm trying to fetch mails. When I run docker exec -it webapps_crm_1 /bin/bash
and then php cron.php
in the /var/www/html
directory, emails are fetched as it should. However, the cron service doesn't do this job.
Is there anything I'm missing?
Hello!
I test a docker installation of EspoCRM. When trying to connect to AD using encryption, I get an error:
>>> Error 500: 0x51 (Can't contact LDAP server; (unknown error code)): ldaps://SERVER:3269
Which means that the CRM couldn't find the CA cert of the AD server. Ok, I googled it and learned that laminas-ldap is used which in turn uses OpenLdap libraries. And here's the problem: there's no OpenLDAP traces in the containers at all (or I couldn't find any).
Then I tried to share the CA from the host to the ssl dir but to no avail:
- espocrm:/var/www/html
- /etc/openldap/certs/CA.cer:/etc/ssl/certs/CA.cer
If using the standart port (389) without encryption, everything works fine, so it's not AD's config problem.
So, how is cert checking realised in the docker version of EspoCRM? Or is it a bug?
Any help would be appreciated. Thanks.
I am running EspoCRM on docker via Portainer. I've had a working system for quite a while, I've made no recent changes. Today I went to upgrade the stack from from 8.0.6 to 8.1.4. Simple process- go to the stack, stop it, re-pull updated images from the repository and re-deploy.
Logs show "upgrading from 8.06" for 45 minutes with no apparent activity. Exec
Run "upgrade" action. Start upgrading process from version 8.0.6. PHP Warning: require(/var/www/html/vendor/composer/../../application/Espo/Resources/defaults/tcpdf-config.php): Failed to open stream: No such file or directory in /var/www/html/vendor/composer/autoload_real.php on line 53 PHP Fatal error: Uncaught Error: Failed opening required '/var/www/html/vendor/composer/../../application/Espo/Resources/defaults/tcpdf-config.php' (include_path='/var/www/html') in /var/www/html/vendor/composer/autoload_real.php:53 Stack trace: #0 /var/www/html/vendor/composer/autoload_real.php(36): composerRequire81e67dd04e1d26db73a6b9676f976909('618029bee273295...', '/var/www/html/v...') #1 /var/www/html/vendor/autoload.php(25): ComposerAutoloaderInit81e67dd04e1d26db73a6b9676f976909::getLoader() #2 /var/www/html/bootstrap.php(33): require_once('/var/www/html/v...') #3 /var/www/html/command.php(30): include('/var/www/html/b...') #4 {main} thrown in /var/www/html/vendor/composer/autoload_real.php on line 53
This is a repeated error until the max upgrade counter limit is reached. The system is not usable at all. I deleted the containers and tried again- same errors. But this time, Apache will "resume normal operations" but the client's still down. Attempts to access it prompt the same error:
[Fri Mar 01 17:39:28.350972 2024] [php:error] [pid 111] [client 10.2.140.1:58672] PHP Fatal error: Uncaught Error: Failed opening required '/var/www/html/vendor/composer/../../application/Espo/Resources/defaults/tcpdf-config.php' (include_path='/var/www/html') in /var/www/html/vendor/composer/autoload_real.php:53\nStack trace:\n#0 /var/www/html/vendor/composer/autoload_real.php(36): composerRequire81e67dd04e1d26db73a6b9676f976909('618029bee273295...', '/var/www/html/v...')\n#1 /var/www/html/vendor/autoload.php(25): ComposerAutoloaderInit81e67dd04e1d26db73a6b9676f976909::getLoader()\n#2 /var/www/html/bootstrap.php(33): require_once('/var/www/html/v...')\n#3 /var/www/html/public/index.php(30): include('/var/www/html/b...')\n#4 {main}\n thrown in /var/www/html/vendor/composer/autoload_real.php on line 53
Running Version 8.2.4 in docker (not docker compose
).
All is working smoothly.
I set up a test personal email account, and connections test OK, test email gets sent properly, etc.
How do I set up a cron job inside the container so that emails get fetched? I looked at the instructions but cannot seem to apply them to using espocrm inside docker container.
I can fire up a shell using docker exec -it espocrm bash
and docker exec -it espocrm bash -c "pgrep cron"
returns nothing.
The admin portal gives this message:
Scheduled jobs are not running. Hence inbound emails, notifications and reminders are not working. Please follow the instructions to setup cron job.
Clueless here. Just getting started with docker so bear with me please.
Note 1: If there is a way to retrieve emails manually, without using a cron job, I might go that route, but I do not think it is possible with espocrm.
Note 2: I tried to fire up a shell and once in, I can see the cron.php
file. If I then go: php -f cron.php
I get this error message: Could not open input file: cron.php
I'd usually think it's a permission problem but I'm logged in as root@........
and pwd
is /var/www/html
.
I think my shell was not inserting the characters of the file name correctly when typing it, for some reason. Using tab completion, the error message above disappeared after running php -f cron.php
. Can't see any cron
process running but the message to setup cron job
(above) is now gone.
Per the Docker's Docker Compose Secrets documentation, most Docker containers are starting to support the recommended _FILE
suffix for sensitive information, allowing Docker Compose to use the more-secure secrets
top-level element.
For example from the MySQL Docker image documentation:
Docker Secrets
As an alternative to passing sensitive information via environment variables,
_FILE
may be appended to the previously listed environment variables, causing the initialization script to load the values for those variables from files present in the container. In particular, this can be used to load passwords from Docker secrets stored in/run/secrets/<secret_name>
files. For example:$ docker run --name some-mysql -e MYSQL_ROOT_PASSWORD_FILE=/run/secrets/mysql-root -d mysql:tagCurrently, this is only supported for
MYSQL_ROOT_PASSWORD
,MYSQL_ROOT_HOST
,MYSQL_DATABASE
,MYSQL_USER
, andMYSQL_PASSWORD
.
By simply adding additional _FILE
environment parameters, this change is entirely backwards compatible and will not disrupt any users that make use of the older .env
pattern.
This pattern is significantly more secure, as .env
files have singular user access control. This also removes sensitive information from existing in the container's environment variables, which is a significant security improvement.
Especially for EspoCRM, there may be a realistic case where a development operations manager may want to give users the ability to manage their ESPOCRM_ADMIN_***
credentials, but not have access to the MySQL database credentials. With the existing .env
pattern, that access is "all or nothing."
Following Docker's official recommendation in the link above, I recommend making seven (7) additional ***_FILE
environment variables in the Dockerfile
to match each of the following, existing variables:
ESPOCRM_DATABASE_HOST
(often DevOps managing remote databases do not wish to expose their hosts to developers)ESPOCRM_DATABASE_PORT
ESPOCRM_DATABASE_NAME
ESPOCRM_DATABASE_USER
ESPOCRM_DATABASE_PASSWORD
ESPOCRM_ADMIN_USERNAME
ESPOCRM_ADMIN_PASSWORD
As an example of what the improved Docker Compose file may look like for your documentation:
name: espocrm
# Note, the `version` top-level element is deprecated. See:
# https://docs.docker.com/compose/compose-file/04-version-and-name/
services:
mysql:
image: mysql:8
container_name: mysql
secrets:
- mysql_root_password
- mysql_database
- mysql_user
- mysql_password
environment:
MYSQL_ROOT_PASSWORD_FILE: "/run/secrets/mysql_root_password"
MYSQL_DATABASE_FILE: "/run/secrets/mysql_database"
MYSQL_USER_FILE: "/run/secrets/mysql_user"
MYSQL_PASSWORD_FILE: "/run/secrets/mysql_password"
volumes:
- mysql:/var/lib/mysql
restart: always
espocrm:
image: espocrm/espocrm
container_name: espocrm
secrets:
- mysql_host
- mysql_port
- mysql_database
- mysql_user
- mysql_password
- espocrm_admin_user
- espocrm_admin_password
environment:
ESPOCRM_DATABASE_PLATFORM: Mysql
ESPOCRM_DATABASE_HOST_FILE: "/run/secrets/mysql_host"
ESPOCRM_DATABASE_PORT_FILE: "/run/secrets/mysql_port"
ESPOCRM_DATABASE_NAME_FILE: "/run/secrets/mysql_database"
ESPOCRM_DATABASE_USER_FILE: "/run/secrets/mysql_user"
ESPOCRM_DATABASE_PASSWORD_FILE: "/run/secrets/mysql_password"
ESPOCRM_ADMIN_USERNAME_FILE: "/run/secrets/espocrm_admin_user"
ESPOCRM_ADMIN_PASSWORD_FILE: "/run/secrets/espocrm_admin_password"
ESPOCRM_SITE_URL: "http://localhost:8080"
volumes:
- espocrm:/var/www/html
restart: always
ports:
- 8080:80
espocrm-daemon:
image: espocrm/espocrm
container_name: espocrm-daemon
volumes:
- espocrm:/var/www/html
restart: always
entrypoint: docker-daemon.sh
espocrm-websocket:
image: espocrm/espocrm
container_name: espocrm-websocket
environment:
ESPOCRM_CONFIG_USE_WEB_SOCKET: "true"
ESPOCRM_CONFIG_WEB_SOCKET_URL: "ws://localhost:8081"
ESPOCRM_CONFIG_WEB_SOCKET_ZERO_M_Q_SUBSCRIBER_DSN: "tcp://*:7777"
ESPOCRM_CONFIG_WEB_SOCKET_ZERO_M_Q_SUBMISSION_DSN: "tcp://espocrm-websocket:7777"
volumes:
- espocrm:/var/www/html
restart: always
entrypoint: docker-websocket.sh
ports:
- 8081:8080
volumes:
mysql:
espocrm:
# The `secrets` directory should have `770` permissions and be owned by the
# user/group running the Docker daemon (usually `root`).
secrets:
mysql_host:
file: "./secrets/mysql/host"
mysql_port:
file: "./secrets/mysql/port"
mysql_database:
file: "./secrets/mysql/database_name"
mysql_root_password:
file: "./secrets/mysql/root_password"
mysql_database:
file: "./secrets/mysql/database"
mysql_user:
file: "./secrets/mysql/user"
mysql_password:
file: "./secrets/mysql/password"
espocrm_admin_user:
file: "./secrets/espocrm/admin_username"
espocrm_admin_password:
file: "./secrets/espocrm/admin_password"
As an example for implementation of this change, here is how MySQL manages this:
And WordPress, as a more dynamic alternative:
Could you provide feedback on best practices for managing data/config.php with a docker build of EspoCRM?
This file contains configuration that needs to be persisted across a cluster of web nodes, for example, tabList and smtp settings, therefore I would like to track the file in our git repo and include it in our build of the app, but doing this with the stock docker image causes the Espo installation process to fail because the installer thinks that the app has already been installed if this file is present. Also config.php contains values like siteUrl that should not be baked into the image since it needs to be per environment.
Unfortunately that doesn't fix it as you are using apt-mark and apt-get purge with auto-remove. The package doesn't end up in the final docker image. You need to install it here
https://github.com/espocrm/docker/blob/master/Dockerfile-debian.template#L65
or put it outside of your apt-mark.
Originally posted by @jasonheffner in #8 (comment)
I'm trying to work through installing on Kubernetes, and I'm at a point where enabling debug logging would be useful.
I can override values in config.php using Config Environments (https://docs.espocrm.com/administration/log/) but the logger
setting is an array, and there's no example of how to do this.
Is it possible to set an array config value from the environment?
I have not yet been able to send an email via my espocrm test personal email account, but shouldn't I already be able to see the existing (previously) sent emails in the `Inbox.sent' folder of the IMAP account?
How does one configure that?
It would be nice if we could add the outgoing mail / SMTP configuration in the environment for the docker-compose. Something like SMTP_HOST, SMTP_USER, SMTP_PASS, so this can be set here instead of having to configure it manually in the webgui.
Same thing with LDAP settings.
PostgreSQL support is currently broken due to no system libraries or PDO drivers installed inside the Debian or Alpine images.
Required libraries:
libpq-dev
postgresql-dev
Required PHP extension:
pdo_pgsql
Created pull request #31 with fixes for all images.
How can we use with traefik reverse proxy
I'm using all of my apps with Traefik. I setup my docker compose file but it didn't worked for espocrm docker-compose.yml file.
So if I missed anything can you guys help me out.
My docker-compose.yml file down below.
`
version: '3.8'
services:
mysql:
image: mysql:8
container_name: mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: root_password
MYSQL_DATABASE: espocrm
MYSQL_USER: espocrm
MYSQL_PASSWORD: database_password
command: --default-authentication-plugin=mysql_native_password
networks:
- espocrm
volumes:
- /storage/espocrm/mysql:/var/lib/mysql
labels:
- "traefik.enable=false"
espocrm:
image: espocrm/espocrm
container_name: espocrm
environment:
ESPOCRM_DATABASE_HOST: mysql
ESPOCRM_DATABASE_USER: espocrm
ESPOCRM_DATABASE_PASSWORD: database_password
ESPOCRM_ADMIN_USERNAME: admin
ESPOCRM_ADMIN_PASSWORD: password
ESPOCRM_SITE_URL: "https://espocrm.mydomain.com"
networks:
- espocrm
- proxy
volumes:
- /storage/espocrm:/var/www/html
labels:
- "traefik.enable=true"
- "traefik.http.routers.espocrm.rule=Host(espocrm.mydomain.com
)"
- "traefik.http.services.espocrm.loadbalancer.server.port=8080"
- "traefik.http.routers.espocrm.entrypoints=websecure"
- "traefik.http.routers.espocrm.tls=true"
- "traefik.http.routers.espocrm.tls.certresolver=cloudflare"
- "traefik.http.routers.espocrm.tls.domains[0].main=espocrm.mydomain.com"
restart: always
expose:
- 8080
espocrm-daemon:
image: espocrm/espocrm
container_name: espocrm-daemon
networks:
- espocrm
volumes:
- /storage/espocrm:/var/www/html
restart: always
entrypoint: docker-daemon.sh
espocrm-websocket:
image: espocrm/espocrm
container_name: espocrm-websocket
environment:
ESPOCRM_CONFIG_USE_WEB_SOCKET: "true"
ESPOCRM_CONFIG_WEB_SOCKET_URL: "ws://espocrm.mydomain.com"
ESPOCRM_CONFIG_WEB_SOCKET_ZERO_M_Q_SUBSCRIBER_DSN: "tcp://*:7777"
ESPOCRM_CONFIG_WEB_SOCKET_ZERO_M_Q_SUBMISSION_DSN: "tcp://espocrm-websocket:7777"
volumes:
- /storage/espocrm:/var/www/html
networks:
- espocrm
restart: always
entrypoint: docker-websocket.sh
expose:
- 8081
- 7777
networks:
espocrm:
driver: bridge
proxy:
external:
name: "traefik_proxy"
volumes:
mysql:
espocrm:
`
Hello,
Similar to #29, latest releases are not available via DockerHub (8.1.1 → 8.1.3)
As a workaround, I can trigger the upgrade manually in the container via docker exec -i espocrm php bin/command upgrade -y
Regards.
The docker tags for releases 8.0.3 and 8.0.4 have not been published yet. Will they be published or are users expected to build their own images as of 8.0.3?
Hello,
We have a problem with espocrm in docker container with email attachments.
OS: Ubuntu 20.04.3 LTS
EspoCRM: 6.1.9
The link it's something like this: http://xxxxxxxxxxxxxxxxx/?entryPoint=download&id=612cef357d840f5b3
I can see the attachment on filesystem but on the crm web I can't.
Thank you.
Nearly all managed database providers use non-standard ports, but there is no ESPOCRM_DATABASE_PORT
option. This prevents every hosting use-case except for self-hosted containers (which is a really, really bad idea in production).
I would personally treat this as urgent...
Closing espocrm/espocrm#3074 as I believe this belongs here.
Hello,
We want to migrate our espocrm from standard installation to docker version but I have some questions about this [the default docker-compose it's working fine with mysql container].
With this config I'm getting Error 500.
version: '3.1'
services:
espocrm:
container_name: espocrm
image: espocrm/espocrm
environment:
ESPOCRM_DATABASE_HOST: 192.168.3.107
ESPOCRM_DATABASE_NAME: crm
ESPOCRM_DATABASE_USER: crm
ESPOCRM_DATABASE_PASSWORD: 123456
ESPOCRM_ADMIN_USERNAME: admin
ESPOCRM_ADMIN_PASSWORD: password
ESPOCRM_SITE_URL: "http://localhost:8080"
restart: always
ports:
- 8282:80
volumes:
- ./data:/var/www/html
- ./docs:/var/www/html/epsocrm/data/upload
espocrm-daemon:
image: espocrm/espocrm
volumes:
- ./data:/var/www/html
restart: always
entrypoint: docker-daemon.sh
volumes:
espocrm:
Thank you.
Running Version 8.2.4 in docker (not docker compose).
I have setup a test personal email account. incoming and outgoing (smtp) IS configured in the personal email account configuration AND the test email does get sent (and received by recipient.)
When I select "Reply", I get the following error messages:
SMTP is not configured: Personal Email Accounts
Although the smtp
is configured.
I also went to Administration|Outbound emails
and set the smtp there even though somehow it does not ask me for a password in that screen.
If I try to send an email I get the following error message:
Error 400: Bad request
Backend validation failure.
Field: from
Validation: required
What's going on here?
As discovered in this issue: espocrm/espocrm#2758
In my last 5 instances of deploying EspoCRM
using the docker implementation,data/config-internal.php
ended up with charset
being stored as NULL
which then broke emojis across the board. Error 500
and then in the log:
ERROR: (HY000) SQLSTATE[HY000]: General error: 1366 Incorrect string value:
Posting this here for myself unless someone answers it and corrects the implementation before me.
Hello,
It is possible in docker compose insert other espo crm database port?
like this:
environment:
ESPOCRM_DATABASE_HOST: mysql
ESPOCRM_DATABASE_PORT: 3307
ESPOCRM_DATABASE_USER: espocrm
I see in data/config-internal.php:
'database' => [
'driver' => 'pdo_mysql',
'dbname' => 'YOUR_DATABASE_NAME',
'user' => 'YOUR_USER',
'password' => 'YOUR_DATABASE_PASSWORD',
'host' => 'localhost',
'port' => '',
],
Thank you.
Describe the bug
We can't see some documents (PDF's with 5MB+). The upload it's fine but the app can't open it.
Error we get 403 Forbidden.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
To see all the documents (bigger or smaller).
EspoCRM version
EspoCRM Version 7.2.4 in docker container with external database.
Additional context
Both documents (1 and 2 from SS) are the same.
The first one it's a smaller copy from the second one.
The first document I can open.
The second document I can't open.
I get this in logs:
[2022-10-05 06:25:03] ERROR: (403) GET /; line: 85, file: /var/www/html/application/Espo/EntryPoints/Download.php [] []
[2022-10-05 06:25:13] ERROR: (403) GET /; line: 85, file: /var/www/html/application/Espo/EntryPoints/Download.php [] []
[2022-10-05 06:32:30] ERROR: (403) GET /; line: 85, file: /var/www/html/application/Espo/EntryPoints/Download.php [] []
[2022-10-05 06:33:12] ERROR: (403) GET /; line: 85, file: /var/www/html/application/Espo/EntryPoints/Download.php [] []
[2022-10-05 06:33:24] ERROR: (403) GET /; line: 85, file: /var/www/html/application/Espo/EntryPoints/Download.php [] []
In settings:
So the size should not be a problem.
Thank you.
When I upgrade EspoCRM version via Dockerhub, so pull the espocrm/espocrm:latest
or espocrm/espocrm:{tag}
I then need to delete the container used by previous image and create a new one to run the upgraded image.
This seems to cause all EspoCRM settings (not the Mysql settings) to be lost: currency, locale, smtp passwords, all of that has to be re-inserted, upon every upgrade.
Is there a way to have these settings persist across upgrades?
I use docker (not docker-compose
.)
Note: posted in the forum but no replies there.
Is this website a joke? As it seems to be hosted by you
Release: 7.3.2 in Docker.
I updated from 7.2.7 to 7.3.2 and found that no Scheduled Jobs were running (Check Group Email Accounts & Run Scheduled Workflows specifically).
Issues subsided after un-checking : Job Settings > "Jobs Run in Parallel"
In html/data/logs is:
WARNING: Cron is not run because it's disabled with 'cronDisabled' param. [] []
ERROR: Uncaught Exception Spatie\Async\Output\ParallelError: "PHP Deprecated: Opis\Closure\SerializableClosure implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in /var/www/html/vendor/opis/closure/src/SerializableClosure.php on line 18 " at /var/www/html/vendor/spatie/async/src/Output/ParallelError.php line 11 {"exception":"[object] (Spatie\\Async\\Output\\ParallelError(code: 0): PHP Deprecated: Opis\\Closure\\SerializableClosure implements the Serializable interface, which is deprecated. Implement __serialize() and __unserialize() instead (or in addition, if support for old PHP versions is necessary) in /var/www/html/vendor/opis/closure/src/SerializableClosure.php on line 18\n at /var/www/html/vendor/spatie/async/src/Output/ParallelError.php:11)"} []
May have something todo with dropping PHP 7.4 support in release 7.3.0?
Related? espocrm/espocrm#1283 & Forum Post
It would be nice to be able to use "Jobs run in parallel" as it sounds like it is highly recommended.
Describe the bug
When setting EspoCRM up via Docker, and trying to create a new Entity, a 500 Error is returned with the following in the logs:
[2024-06-18 22:11:45] WARNING: E_WARNING: mkdir(): Permission denied {"code":2,"message":"mkdir(): Permission denied","file":"/var/www/html/application/Espo/Core/Utils/File/Manager.php","line":561}
[2024-06-18 22:11:45] WARNING: E_WARNING: mkdir(): No such file or directory {"code":2,"message":"mkdir(): No such file or directory","file":"/var/www/html/application/Espo/Core/Utils/File/Manager.php","line":561}
[2024-06-18 22:11:45] ERROR: (0) Permission denied: unable to create a folder on the server custom/Espo/Custom/Resources/i18n/en_US; POST /EntityManager/action/createEntity; line: 700, file: /var/www/html/application/Espo/Core/Utils/File/Manager.php
The Entity will not appear in the list, but trying to create another Entity of the same name will create a 409
error similar to:
[2024-06-18 22:11:47] ERROR: (409) Name 'CService' is already used.; POST /EntityManager/action/createEntity; line: 61, file: /var/www/html/application/Espo/Core/Exceptions/Conflict.php
To Reproduce (MANDATORY, DO NOT REMOVE)
Explicit steps to reproduce the behavior:
Expected behavior
The Docker container should have its directory permissions configured appropriately as part of the build. As of right now, the volume permissions need to be manually changed after the Docker container is created and the volume is populated.
Screenshots
N/A
EspoCRM version
Whatever the version is just-prior to the 8.2.5
update - presumably 8.2.4
.
Note - please put your version in your footer or on the Administration page. As I type this I don't know where to go to find the version, as I'm using the
latest
tag for my container.
Additional context
It seems that EspoCRM creates the database entry even though the system threw an error - this is bad transaction practice. The entire database entry should be wrapped in a transaction and rolled back if an error like this occurs.
Right now, my system is in a state where I can't create the Entities I need, because the database records exist, but the failure to update the filesystem (whatever it was) causes it to not appear in my administration.
Any advice on how I can repair my existing setup would be appreciated. I can delete records in the database, I just need to know which ones and if they appropriately cascade to any foreign records.
Hello Team,
Thanks for packaging this together. I have tried using the docker directly on Kubernetes but its not been working no matter what I do.
this is an example of my statefulset but its returning 504 error when I try to access the service
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: watuespocrm
labels:
tier: backend
spec:
replicas: 1
serviceName: "watuespocrm"
selector:
matchLabels:
app: watuespocrm
template:
metadata:
labels:
app: watuespocrm
spec:
containers:
- name: watu-espocrm
image: espocrm/espocrm:fpm-alpine
ports:
- containerPort: 80
name: http
volumeMounts:
- name: espo-crm-volume
mountPath: "/var/www/html"
env:
- name: ESPOCRM_DATABASE_HOST
value: ${DB_HOST}:${DB_PORT}
- name: ESPOCRM_DATABASE_USER
value: ${DB_USERNAME}
- name: ESPOCRM_DATABASE_PASSWORD
value: ${DB_PASSWORD}
- name: ESPOCRM_ADMIN_USERNAME
value: "admin"
- name: ESPOCRM_ADMIN_PASSWORD
value: "adminPassword"
- name: ESPOCRM_SITE_URL
value: "https://espocrm.watu.global"
- name: watu-espocrm-daemon
image: espocrm/espocrm:fpm-alpine
volumeMounts:
- mountPath: "/var/www/html"
name: "espo-crm-volume"
command: ["docker-daemon.sh"]
- name: watu-espocrm-websocket
image: espocrm/espocrm:fpm-alpine
ports:
- containerPort: 8080
volumeMounts:
- mountPath: "/var/www/html"
name: "espo-crm-volume"
command: ["docker-websocket.sh"]
restartPolicy: Always
volumeClaimTemplates:
- metadata:
name: espo-crm-volume
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 5Gi
storageClassName: do-block-storage
EspoCRM 6.1.10, and 6.1.9
LDAP authentication not working in Docker Hub image. LDAP Authentication working fine when I build using...
docker-compose.yml
image: crm-webapp:${espo_version}
build:
context: ./docker/apache
dockerfile: Dockerfile
CI job
- cd ./docker/apache
- docker build --no-cache -t crm-webapp:${espo_version} -f Dockerfile .
Ldap authentication has been working for multiple versions. I wanted to switch to Docker Hub image. When trying to use docker hub image authentication will not work. I can easily swap in/out docker hub image and going from working to not working and vice versa. Here was the image I tried...
docker-compose.yml
image: espocrm/espocrm:6.1.10-apache
I'm not sure what the differences are/or if you are missing ldap libraries in the docker hub version.
When using docker, either configuring everything manually with a regular setup or when using the install script, websocket is not working. Something seems to be missing from a regular setup using php. It seems nginx are not able to understans or translate the zmq and hence not becoming a socket. Instead only reaching the endpoint over http(s).
After spending countless hours on this I decided to cash up for a VM to try it outside my current hosting setup and came to the same conclusion result. Or I might be missing something fundamental, if so I'd love some help.
"auto-install" with ssh:
# MODE: letsencrypt
version: '3'
services:
espocrm-mysql:
image: mysql:8
container_name: espocrm-mysql
command: --default-authentication-plugin=mysql_native_password
restart: always
environment:
MYSQL_ROOT_PASSWORD: pass
MYSQL_DATABASE: espocrm
MYSQL_USER: espocrm
MYSQL_PASSWORD: pass
volumes:
- ./data/mysql/data:/var/lib/mysql
networks:
- internal
espocrm-nginx:
image: nginx
container_name: espocrm-nginx
restart: always
depends_on:
- espocrm
volumes:
- ./data/nginx/conf.d/:/etc/nginx/conf.d/
- ./data/espocrm:/var/www/html
- ./data/nginx/espocrm.conf:/etc/nginx/espocrm.conf
- ./data/nginx/logs:/var/log/nginx
- ./data/nginx/ssl:/etc/nginx/ssl
- ./data/nginx/certbot:/var/www/certbot
ports:
- "80:80"
- "443:443"
command: "/bin/sh -c 'while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g \"daemon off;\"'"
networks:
- external
espocrm:
image: espocrm/espocrm:fpm
container_name: espocrm
environment:
ESPOCRM_DATABASE_HOST: espocrm-mysql
ESPOCRM_DATABASE_USER: espocrm
ESPOCRM_DATABASE_PASSWORD: pass
ESPOCRM_ADMIN_USERNAME: admin
ESPOCRM_ADMIN_PASSWORD: pass
ESPOCRM_SITE_URL: "https://espocrm.domain.tld"
ESPOCRM_CONFIG_WEB_SOCKET_ZERO_M_Q_SUBMISSION_DSN: "tcp://espocrm-websocket:7777"
restart: always
depends_on:
- espocrm-mysql
volumes:
- ./data/espocrm:/var/www/html
networks:
- external
- internal
espocrm-daemon:
image: espocrm/espocrm:fpm
container_name: espocrm-daemon
volumes:
- ./data/espocrm:/var/www/html
restart: always
depends_on:
- espocrm
entrypoint: docker-daemon.sh
networks:
- external
- internal
espocrm-websocket:
container_name: espocrm-websocket
image: espocrm/espocrm:fpm
environment:
ESPOCRM_CONFIG_WEB_SOCKET_ZERO_M_Q_SUBSCRIBER_DSN: "tcp://*:7777"
ESPOCRM_CONFIG_USE_WEB_SOCKET: "true"
volumes:
- ./data/espocrm:/var/www/html
restart: always
depends_on:
- espocrm
entrypoint: docker-websocket.sh
ports:
- 8080:8080
networks:
- external
- internal
espocrm-certbot:
image: certbot/certbot
container_name: espocrm-certbot
restart: always
volumes:
- ./data/nginx/ssl:/etc/letsencrypt
- ./data/nginx/certbot:/var/www/certbot
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
networks:
- external
networks:
external:
external: true
internal:
external: false
Can the development team push the new version and tag 8.3.0
to hub.docker.com
please?
We are using renovate to check for updates and it would be very convenient to have release notes in the dependency-dashboard/commit comments. To enable this the images should have this label (see renovate docs):
LABEL org.opencontainers.image.source="https://github.com/espocrm/espocrm"
More useful labels can be found here: opencontainers/image-spec
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.