I can not run the command ./bin/cake passbolt send_test_email

I am using passbolt with docker-compose and everything was going well, when I try to make the registration to start using and do the registration the email never arrives. And when I try to run the command ./bin/cake passbolt send_test_email, the message is: file not found. I’m new to docker and passbolt, I’m sorry if the question is silly.

1 Like

Hi @ludibela! Sorry for the late reply!

Have you set up the EMAIL_* environment variables in the file env/passbolt.env ? For instance a passbolt.env file that would use gmail as SMTP provider would look like this:

EMAIL_TRANSPORT_DEFAULT_PASSWORD=your_password
EMAIL_DEFAULT_FROM=no-reply@yourdomain.com
EMAIL_TRANSPORT_DEFAULT_USERNAME=your@username
EMAIL_TRANSPORT_DEFAULT_TLS=true
EMAIL_TRANSPORT_DEFAULT_HOST=smtp.yourhost.com
EMAIL_TRANSPORT_DEFAULT_PORT=your_smtp_provider_port

Once you have that file is in place run docker-compose up and test the email sending via connecting to your docker container and executing /var/www/passbolt/bin/cake passbolt send_test_email or using the regular registration process and see if the email arrives.

If that still doesn’t solve your problem please provide a snip of the logs located in /var/www/passbolt/logs/error.log or the complete output of the execution of: /var/www/passbolt/bin/cake/passbolt send_test_email

1 Like

Hi,

Thanks so much for answer me, I think maybe I have made something wrong, because I don’t have this file too (/var/www/passbolt/bin/cake/passbolt ) I got the same error, I can’t have sucess find cake. After setup email variables in /env/passbolt I go to /var/ folder and inside this don’t have a www folder, I just followed the step-by-step tutorial in https://help.passbolt.com/hosting/install/ce/docker.html and everything works fine, but when I try register new user in https://passbolt.local the email never comming. This is my first project using docker and docker compose. I don’t see any php file in passbolt configuration folders.

Hi again,

Sorry there was a typo in my previous reply it’s not /var/www/passbolt/bin/cake/passbolt but /var/www/passbolt/bin/cake passbolt

In the instructions you point at keep in mind that the EMAIL setup is omitted in both the manual and docker-compose setup and the user registration is being done executing a command inside the container like this:
(Assuming you have your passbolt and mysql containers running)

:~$ docker exec passbolt_docker_passbolt_1 su -m -c "/var/www/passbolt/bin/cake \                                              
                                passbolt register_user \
                                -u username@email.local \
                                -f my_name \
                                -l my_surname \
                                -r admin" -s /bin/sh www-data

     ____                  __          ____
    / __ \____  _____ ____/ /_  ____  / / /_
   / /_/ / __ `/ ___/ ___/ __ \/ __ \/ / __/
  / ____/ /_/ (__  |__  ) /_/ / /_/ / / /
 /_/    \__,_/____/____/_.___/\____/_/\__/

 Open source password manager for teams
---------------------------------------------------------------
User saved successfully.
To start registration follow the link in provided in your mailbox or here:
https://passbolt.local/setup/install/8de983e6-425a-42e3-8efa-af7f56f409e9/457a9b2b-1de0-464d-b2c6-fc2757d14d98          

It returns an URL that you can use to paste in your browser and finish the registration process. Keep in mind that for inexistent domains like the one of this example you would require to update your /etc/hosts.

Hope this helps!

1 Like

Its running, your last reply solved all my problems, thanks @diego !

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.