Passbolt install in a subfolder

Hi everyone !
This is my first time on this forum but i really need some help.
Moreover, my english is not very good, i’ll do my best :).

So, i want to have Passbolt in a subfolder of my web server like http://localhost/passbolt/.
Because now, i need to have another web site.

However, i do my best in order to fine a solution but it doesn’t work…
I know, in the official documentation they say : " Note: the configuration does not support serving passbolt on a subdirectory fashion. For example, scenarios like are not supported by default"

How can i activate this feature?
I tried to modify this file : “/etc/passbolt/passbolt.default.php”, with ‘base’ => ‘/passbolt’. It didn’t work.
I tried to play with my location in “/etc/nginx/sites-available/default” but no success too…

Can i have some help, cause i really need that.

Best regard.

Hi @MrPass This normally can be handled by the web server, so you’re on the right track. You are using NGINX, so this might help:

It also would be wise to make the other site you have on the server also serve from a unique, established path so there is no confusion. Paths (subfolders) are useful when you have control over the call to the server. Otherwise, you might want to go with a subdomain approach instead.

1 Like

First, thanks for your answer !

This is very helpful.
However, i have another problem now…

Phpinfo page work at the /, so PHP-FPM is running and the configuration is good.
At the /passbolt path, the PHP code is not executed but downloaded…

I know that is a problem from PHP-FPM but i don’t know what i am doing wrong.
Mostly, it works on my root…
I’ve made some search on the web but nothing works for me.

So, can i have help on this part too?


@MrPass Can you provide your NGINX configuration? And maybe now there are errors in the logs? Found: /var/log/nginx/*

1 Like

I’ve found a solution, after few days of searching !
Thanks for your help, i understand how it work the server block and location in NGINX.

First, i will reinstall by sources because the package configure nginx automatically.
Cause, with the package, when i try to modify passbolt.default.php, this configuration was not loaded.
So, by sources, i can modify this configuration before that nginx was configured.
I’ve modified this file : “/etc/passbolt/passbolt.default.php”, with ‘base’ => ‘/passbolt’.
Then i run the install script.

After that, i’ve deleted the nginx-passbolt.default.conf in /var/www/nginx/sites-enabled/ and i put this conf in the default configuration in /var/www/nginx/sites-enabled/:

	location ^~ /passbolt {
		alias /var/www/passbolt/webroot; 
		try_files $uri $uri/ @passbolt;

		location ~ \.php$ {
	        include 			snippets/fastcgi-php.conf;
 			fastcgi_param 	SCRIPT_FILENAME $request_filename; 

	location @passbolt {
		rewrite /passbolt/(.*)$ /passbolt/index.php?/$1 last;

And, now I can access to my Passbolt by http://localhost/passbolt !
Hope that can help someone else.

Regards ! :slight_smile:


Thanks for posting your findings!

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