phpMyAdmin Install Guide
step-by-step guide to installing and configuring phpMyAdmin on gentoo
The phpMyAdmin installation documentation should be referenced, and supercedes any information provided here.
Process
- Presumably MySQL is already installed. phpMyAdmin doesn't make much sense without it.
- install phpMyAdmin
-
echo "dev-db/phpmyadmin ~x86" >> /etc/portage/package.keywords
-
emerge -avt phpmyadmin
- if you're using vhosts with apache, the emerge doesn't actually create a usable phpmyadmin instance, you have to use webapp-config to finish:
- first, edit the webapp-config configuration file to ensure its defaults are appropriate
-
vim /etc/vhosts/webapp-config
- now use webapp-config to install the instance of the application
-
webapp-config -I -h <vhostname> -u <username> -g <groupname> --secure -d <vhost_subdir> phpmyadmin 3.1.1
- where '<vhost_subdir>' is a directory name under your vhost's rootdir where you want the instance to live, and '3.1.1' is the version of phpMyAdmin that you're installing
- <username> and <groupname> are used to establish ownership of the files once they're installed. You should specify the user/group under which your webserver (apache) runs. Alternatively, omit these arguments and ensure that the corrsponding values are set correctly in /etc/vhosts/webapp-config.
- An example of the above command is as follows:
-
webapp-config -I -h negativesum -u apache -g apache --secure -d raw/phpmyadmin phpmyadmin 3.1.1
- if that works successfully, you'll find all of the phpMyAdmin files in <vhost_dir>/<vhost_subdir>.
- use 'man webapp-config' and /etc/vhosts/webapp-config for further details
- configure phpMyAdmin
- copy config.sample.inc.php to config.inc.php
- edit config.inc.php:
-
$cfg['blowfish_secret'] = '<some random string>';
- point your browser at https://yoursite/phpmyadmin to see if things are kosher.
-
login (via http://yoursite/phpmyadmin) using a valid mysql login. Note that phpMyAdmin maintains no notion of user account itself -- it defers entirely to mysql.
Finished!