diff --git a/appstore.js b/appstore.js index 7efdcb2..31331e3 100644 --- a/appstore.js +++ b/appstore.js @@ -103,7 +103,7 @@ AppStore.prototype.waitForCloudron = function (boxId) { // check for ready state if (!boxInfo || boxInfo.status !== 'ready') throw new Error('waitForCloudron: could not get cloudron status'); - debug('Box created in %s minutes with IP:%s'.green, (new Date() - creationTime) / 60000, res.body.box.ip); + debug('Box created in %s minutes with IP:%s (static: %s)'.green, (new Date() - creationTime) / 60000, res.body.box.ip, res.body.box.staticIp); // even if the cloudron sent heartbeat to appstore, doesn't mean we can contact the cloudron thanks to DO networking insanity process.stdout.write('Waiting for Cloudron to be reachable.'); diff --git a/cloudron.js b/cloudron.js index b96a547..3e9d8ba 100644 --- a/cloudron.js +++ b/cloudron.js @@ -449,7 +449,7 @@ Cloudron.prototype.checkA = function (callback) { if (error) return callback(error); if (records.length !== 1) return callback(new Error('Got ' + JSON.stringify(records) + ' A records. Expecting 1 length array')); - if (records[0] !== that._box.ip) return callback(new Error('Bad A record. ' + records[0] + '. Expecting ' + that._box.ip)); + if (records[0] !== that._box.staticIp) return callback(new Error('Bad A record. ' + records[0] + '. Expecting ' + that._box.staticIp)); callback(null, records); }); diff --git a/test/cloudron-backup-test.js b/test/cloudron-backup-test.js index e5b1338..a32708c 100644 --- a/test/cloudron-backup-test.js +++ b/test/cloudron-backup-test.js @@ -155,9 +155,9 @@ describe('Cloudron backup testing', function () { it('wait for local dns', function () { for (var i = 0; i < 50; i++) { var ip = dnsSync.resolve(box.domain); - if (ip === box.ip) return; + if (ip === box.staticIp) return; - console.log('waiting for local dns to change from %s to %s', ip, box.ip); + console.log('waiting for local dns to change from %s to %s', ip, box.staticIp); sleep(30); } });