diff options
Diffstat (limited to 'server.ts')
-rw-r--r-- | server.ts | 11 |
1 files changed, 8 insertions, 3 deletions
@@ -1,6 +1,4 @@ | |||
1 | // FIXME: https://github.com/nodejs/node/pull/16853 | 1 | // FIXME: https://github.com/nodejs/node/pull/16853 |
2 | import { ScheduleVideoUpdateModel } from './server/models/video/schedule-video-update' | ||
3 | |||
4 | require('tls').DEFAULT_ECDH_CURVE = 'auto' | 2 | require('tls').DEFAULT_ECDH_CURVE = 'auto' |
5 | 3 | ||
6 | import { isTestInstance } from './server/helpers/core-utils' | 4 | import { isTestInstance } from './server/helpers/core-utils' |
@@ -26,7 +24,7 @@ process.title = 'peertube' | |||
26 | const app = express() | 24 | const app = express() |
27 | 25 | ||
28 | // ----------- Core checker ----------- | 26 | // ----------- Core checker ----------- |
29 | import { checkMissedConfig, checkFFmpeg, checkConfig } from './server/initializers/checker' | 27 | import { checkMissedConfig, checkFFmpeg, checkConfig, checkActivityPubUrls } from './server/initializers/checker' |
30 | 28 | ||
31 | // Do not use barrels because we don't want to load all modules here (we need to initialize database first) | 29 | // Do not use barrels because we don't want to load all modules here (we need to initialize database first) |
32 | import { logger } from './server/helpers/logger' | 30 | import { logger } from './server/helpers/logger' |
@@ -191,6 +189,13 @@ async function startApplication () { | |||
191 | 189 | ||
192 | await installApplication() | 190 | await installApplication() |
193 | 191 | ||
192 | // Check activity pub urls are valid | ||
193 | checkActivityPubUrls() | ||
194 | .catch(err => { | ||
195 | logger.error('Error in ActivityPub URLs checker.', { err }) | ||
196 | process.exit(-1) | ||
197 | }) | ||
198 | |||
194 | // Email initialization | 199 | // Email initialization |
195 | Emailer.Instance.init() | 200 | Emailer.Instance.init() |
196 | await Emailer.Instance.checkConnectionOrDie() | 201 | await Emailer.Instance.checkConnectionOrDie() |