File tree 1 file changed +10
-1
lines changed
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,11 @@ util.inherits(Vapor, EventEmitter);
41
41
Vapor . prototype . init = function ( config ) {
42
42
this . config = config ;
43
43
44
+ // Set login values from ENV variables if possible
45
+ // Username needs to be preserved
46
+ this . config . username = process . env . VAPOR_USER || config . username ;
47
+ this . config . password = process . env . VAPOR_PASS || config . password ;
48
+
44
49
// Initiate our logger
45
50
this . log = require ( './logger' ) ( config ) ;
46
51
@@ -85,6 +90,10 @@ Vapor.prototype._login = function(username, password) {
85
90
this . client . logOn ( loginOptions ) ;
86
91
} ;
87
92
93
+ /**
94
+ * Plugin loader.
95
+ * @private
96
+ */
88
97
Vapor . prototype . _loadPlugins = function ( ) {
89
98
var vapor = this ;
90
99
var config = this . config ;
@@ -124,7 +133,7 @@ Vapor.prototype._loadPlugins = function() {
124
133
125
134
vapor . log . error ( errors [ 0 ] ) ;
126
135
vapor . log . error ( errors [ 1 ] ) ;
127
-
136
+
128
137
// Being able to load all plugins is critical, abort
129
138
process . exit ( 1 ) ;
130
139
}
You can’t perform that action at this time.
0 commit comments