[Solved]Passbolt installation on CentOS + Cpanel with php-fpm

Hi all,

It takes me a long time but as i didn’t find solution on this forum, I post how I managed to do it.
First, don’t use CentOS package, it doesn’t work well with Cpanel.
I will only note things which differs from official tutorial to install passbolt from source.

First install dependencies:
With php 7.x you may need to enable popen function to be able to install needed packages.
Go to /opt/cpanel/ea-php7x/root/etc/php.ini and edit :
disable_functions = show_source, system, shell_exec, passthru, exec, popen, proc_open
to
disable_functions = show_source, system, shell_exec, passthru, exec, proc_open

> yum -y install unzip wget policycoreutils-python git gcc

then Install gnupg and imagick by using WHM => module installer => pecl (for each version of php you want to use)

if passbolt is not at the root of your DocumentRoot, you need to add needed directives to make it work:
create a virtualhost.conf (you can put any name) in /etc/apache2/conf.d/userdata/ssl/2_4/cpanelusername/domainname/
put this : DocumentRoot /home/cpanelusername/domainname/passbolt and save
Run /scripts/ensure_vhost_includes --user=cpanelusername

if you use fpm, edit (or create) : /var/cpanel/userdata/cpanelusername/domainname.php-fpm.yaml
and add :
---
_is_present: 1
php_admin_value_doc_root: { name: 'php_admin_value[doc_root]', value: /home/cpanelusername/domainname/passbolt }
(you need only the last line if file already exist)
then run :
/scripts/php_fpm_config --rebuild
/scripts/restartsrv_apache_php_fpm
/scripts/restartsrv_httpd

(don’t forget to revert back your php.ini to disable popen function)
After that you should be able to follow the tutorial to install passbolt from source.

Last tip, use cpaneluser to run composer and installation script
(so you need to do su cpaneluser and run command like that : ./bin/cake passbolt install instead of sudo su -s /bin/bash -c “./bin/cake passbolt install” www-data)

I’m sorry if it is not easy to understand for everybody, but English is not my language and I’m not fluent beside that, I didn’t take note during my installation so it is a little bit messy.

Good luck !

@Memnochs thanks for sharing!

You’re welcome
Passbolt is a great tools :slight_smile:

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