Merge pull request #889 from SiIky/feat/AkV9XoBg/reenable-pings

feat: send ping and speedtest URLs to machine
This commit is contained in:
Rafael Taranto 2021-11-12 10:07:41 +00:00 committed by GitHub
commit 1e749c3f4f
2 changed files with 20 additions and 4 deletions

View file

@ -51,6 +51,20 @@ const settingsCache = {}
const devMode = argv.dev || options.http
const urlsToPing = [
`us.archive.ubuntu.com`,
`uk.archive.ubuntu.com`,
`za.archive.ubuntu.com`,
`cn.archive.ubuntu.com`
]
const speedtestFiles = [
{
url: 'https://github.com/lamassu/speed-test-assets/raw/main/python-defaults_2.7.18-3.tar.gz',
size: 44668
}
]
function checkHasLightning (settings) {
return configManager.getWalletSettings('BTC', settings.config).layer2 !== 'no-layer2'
}
@ -111,7 +125,9 @@ function poll (req, res, next) {
receipt,
operatorInfo,
machineInfo,
triggers
triggers,
speedtestFiles,
urlsToPing
}
// BACKWARDS_COMPATIBILITY 7.5
// machines before 7.5 expect old compliance