Page 1 of 1

phpMyAdmin custom URL

Posted: Tue Jul 02, 2024 5:05 pm
by iulsplus
Hi everybody.

I am experiencing an issue with configuring an alias for phpMyAdmin on a Debian (Bookworm) server running MyVesta.
I followed the steps to change the default phpMyAdmin location to a custom alias, but I am encountering a blank page when accessing the new URL. Here are the details:

Changes Made:

- Edited the phpMyAdmin configuration file located at /etc/apache2/conf.d/phpmyadmin.conf.
- Added the following lines to configure the new alias:

Code: Select all

Alias /xyzphpmyadmin /usr/share/phpmyadmin

<Directory /usr/share/phpmyadmin>
    Options FollowSymLinks
    DirectoryIndex index.php
    AllowOverride All
    Require all granted
</Directory>
- Restarted apache.

Results

Only a blank page is displayed when I open the new phpMyAdmin URL.
I searched on this forum for solutions, but it looks like the only user who experienced the same problem, never found a solution.

Thank you for any suggestions.

Re: Issue with Alias Configuration for phpMyAdmin on MyVesta - Getting a Blank Page

Posted: Thu Oct 31, 2024 11:12 am
by fsoyer
Hi,
I faced the same issue with last myVesta. I searched for a solution or, at least, a workaround.
I don't find a solution.
I found a workaround :)

The reason is that, strangely, when you change the alias, apache on myVesta search for a directory with the same name. If you set :
Alias /phpmyadmin-secureURL /usr/share/phpmyadmin
in apache logs you see that now it search phpmyadmin in a directory "/usr/share/phpmyadmin-secureURL" :(
This is not a normal behavior, never seen that before, only on myVesta. So I guess an Apache configuration problem, but can't find where or how.

But, the log give use the workaround. Apache search phpmyadmin-secureURL ? Give it phpmyadmin-secureURL !
So :
- in /etc/apache2/conf.d/phpmyadmin.conf change:

Code: Select all

Alias /phpmyadmin-secureURL /usr/share/phpmyadmin-secureURL
and change all references to this directory in this config file (I found it 5 times in the file)
- rename the directory

Code: Select all

mv /usr/share/phpmyadmin /usr/share/phpmyadmin-secureURL
- in the UI, "Server" / your server hostname / configure / DB, modify the "phpMyAdmin URL"
- restart Apache

Code: Select all

systemctl restart apache2
Done.