2
0
mirror of https://github.com/Ride-The-Lightning/RTL synced 2024-11-11 13:10:41 +00:00
RTL/connect.js
ShahanaFarooqui e34d7c196c Channel Alias Included
Channel Alias Included
2018-11-22 20:30:30 -05:00

25 lines
529 B
JavaScript

var fs = require('fs');
var common = require('./common');
var clArgs = require('optimist').argv;
if(undefined !== clArgs.lndir) {
common.lnd_dir = clArgs.lndir;
} else {
if(common.lnd_dir === '') {
common.lnd_dir = __dirname;
}
}
var macaroon = fs.readFileSync(common.lnd_dir + '/admin.macaroon').toString('hex');
var options = {
url: '',
rejectUnauthorized: false,
// resolveWithFullResponse: true,
json: true,
headers: {
'Grpc-Metadata-macaroon': macaroon,
},
form: ''
};
module.exports = options;