mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
feature: support non-standard unix socket (#5724)
* Add support for custom MySQL unix-socket * NULL must be lowercase! * Naive edit of html/install.php * fixup * Refactor dbConnect Use it everywhere * $config needs to be global Don't need to set $database_link * small cleanups
This commit is contained in:
committed by
Neil Lathwood
parent
66d9d54f73
commit
b1a414e785
@@ -92,6 +92,9 @@ db_port = int(config['db_port'])
|
||||
if config['db_host'][:5].lower() == 'unix:':
|
||||
db_server = config['db_host']
|
||||
db_port = 0
|
||||
elif config['db_socket']:
|
||||
db_server = config['db_socket']
|
||||
db_port = 0
|
||||
else:
|
||||
db_server = config['db_host']
|
||||
|
||||
|
Reference in New Issue
Block a user