more debugs
This commit is contained in:
@@ -64,6 +64,7 @@ function initialize(callback) {
|
|||||||
// database dir and we cannot call service scripts until that's done.
|
// database dir and we cannot call service scripts until that's done.
|
||||||
// TODO: make this smarter to not wait for 30secs for the crash-restart case
|
// TODO: make this smarter to not wait for 30secs for the crash-restart case
|
||||||
gPlatformReadyTimer = setTimeout(function () {
|
gPlatformReadyTimer = setTimeout(function () {
|
||||||
|
debug('emitting platform ready');
|
||||||
gPlatformReadyTimer = null;
|
gPlatformReadyTimer = null;
|
||||||
exports.events.emit(exports.EVENT_READY);
|
exports.events.emit(exports.EVENT_READY);
|
||||||
}, 30000);
|
}, 30000);
|
||||||
|
|||||||
@@ -74,8 +74,10 @@ function waitForPendingTasks(callback) {
|
|||||||
|
|
||||||
function platformReady() {
|
function platformReady() {
|
||||||
if (cloudron.isConfiguredSync()) {
|
if (cloudron.isConfiguredSync()) {
|
||||||
|
debug('platformReady: configured, resuming tasks');
|
||||||
resumeTasks();
|
resumeTasks();
|
||||||
} else {
|
} else {
|
||||||
|
debug('platformReady: not configured yet. waiting for configured event');
|
||||||
cloudron.events.on(cloudron.EVENT_CONFIGURED, resumeTasks);
|
cloudron.events.on(cloudron.EVENT_CONFIGURED, resumeTasks);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user