1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-05 02:39:33 +02:00

Optimize torrent URL update

This commit is contained in:
Chocobozzz 2021-08-18 09:14:51 +02:00
parent 9df52d660f
commit 1f6125be8b
No known key found for this signature in database
GPG key ID: 583A612D890159BE
8 changed files with 74 additions and 20 deletions

View file

@ -55,7 +55,7 @@ export class ServersCommand extends AbstractCommand {
}
async waitUntilLog (str: string, count = 1, strictCount = true) {
const logfile = this.server.servers.buildDirectory('logs/peertube.log')
const logfile = this.buildDirectory('logs/peertube.log')
while (true) {
const buf = await readFile(logfile)
@ -80,6 +80,10 @@ export class ServersCommand extends AbstractCommand {
return this.buildDirectory(join('streaming-playlists', 'hls', videoUUID, basename(fileUrl)))
}
getLogContent () {
return readFile(this.buildDirectory('logs/peertube.log'))
}
async getServerFileSize (subPath: string) {
const path = this.server.servers.buildDirectory(subPath)