Hi, I try install passbolt in docker whit docker compose, but i have a problem whit the ENV in docker compose:
DATASOURCES_DEFAULT_PASSWORD_FILE
I am trying to add as a secret inside a file the password for DATASOURCES_DEFAULT_PASSWORD_FILE
but every time I add it as a secret inside the compose ( whether I do it with compose or swarn, I get the same problem:
[Warning] Access denied for user ‘passbolt’@‘XXXXXX’ (using password: NO)
I think the compose not using the datasources variable correctly. I have tried with different versions of passbolt, with no success…
Hello @Witty and welcome to the forum!
The environment variable you are asking for is available to use with docker secrets. If you are not using it, you have to use DATASOURCES_DEFAULT_PASSWORD instead.
To be able to help you in a better way, please follow the guide of the installation issues posts to get all the required information
Could you please send your Docker Compose (and environment variables file, if it exists) to check for errors?
You should change each credential or URL to avoid revealing sensitive information.
passbolt:
# image: passbolt/passbolt:4.4.2-1-pro
image: passbolt/passbolt:4.3.0-1-pro
container_name: passbolt-PRO
hostname: passbolt-pro01
restart: unless-stopped
environment:
# User y pass igual que la DB para que pueda instalar.
APP_FULL_BASE_URL: https://xxxxxxxxxxxxx.com
DATASOURCES_DEFAULT_HOST: “db”
DATASOURCES_DEFAULT_USERNAME: “xxxxxxxxxx” #DATASOURCES_DEFAULT_PASSWORD: “xxxxxxxxxxxx”
DATASOURCES_DEFAULT_PASSWORD_FILE: /run/secrets/datasources
DATASOURCES_DEFAULT_DATABASE: “xxxxx”
PASSBOLT_SSL_FORCE: “true”
If I use the first option without secret with the password of course, then it works, but if I use it as _FILE with a .txt and the password I get the same error every time as I added above…
What I really want is not to have any password in cleartext in the compose, that’s why I open this thread…
I am trying to deploy this compose with passbolt ce. but once it raises the containers, when trying to register a user I get the error again.
For some reason I think the variable:
2024-05-07 11:20:56 error: [Cake\Database\Exception\MissingConnectionException] Connection to Mysql could not be established: SQLSTATE[HY000] [1045] Access denied for user ‘passbolt’@‘172.26.0.3’ (using password: NO) in /usr/share/php/passbolt/vendor/cakephp/cakephp/src/Database/Driver.php on line 144
Caused by: [PDOException] SQLSTATE[HY000] [1045] Access denied for user ‘passbolt’@‘172.26.0.3’ (using password: NO) in /usr/share/php/passbolt/vendor/cakephp/cakephp/src/Database/Driver.php on line 132
2024-05-07 11:20:56 error: Could not connect to Database.