Manual:$wgDBport

Details
Port number used by the database. If left blank, the appropriate port number is used, depending on the DB system being used (as specified by $wgDBtype):


 * MySQL : Unused. Not sure what to do if you need a non-standard port: $wgDBserver with "hostname:port" does not work.
 * Postgres: 5432