mycnf
v1.0.5
Published
Reads MySQL options using my_print_defaults command.
Downloads
5
Maintainers
Readme
mycnf
Reads MySQL options using my_print_defaults command.
Install
npm install mycnf --save
Usage
const mycnf = require('mycnf');
const config = mycnf();
//> { port: '3306', socket: '/tmp/mysql.sock' }
Configuration Options
cmnd
: Path to 'my_print_defaults' command. If nocmnd
is provided, then 'my_print_defaults' command from $PATH is called.file
: Path of config file to read, defaults to reflecting MySQL config (usually ~/.my.cnf).group
: Name of config file group to parse, default to 'client'.
Environment Variables
MYCNF_CMND
MYCNF_FILE
MYCNF_GROUP