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

Update ffmpeg static version for tests

This commit is contained in:
Chocobozzz 2020-11-06 16:43:43 +01:00 committed by Chocobozzz
parent e4bf785617
commit c655c9ef6f
9 changed files with 39 additions and 20 deletions

View file

@ -31,6 +31,10 @@ async function processCreateView (activity: ActivityView | ActivityCreate, byAct
}
const { video } = await getOrCreateVideoAndAccountAndChannel(options)
if (!video.isLive) {
await Redis.Instance.addVideoView(video.id)
}
if (video.isOwned()) {
// Our live manager will increment the counter and send the view to followers
if (video.isLive) {
@ -38,8 +42,6 @@ async function processCreateView (activity: ActivityView | ActivityCreate, byAct
return
}
await Redis.Instance.addVideoView(video.id)
// Forward the view but don't resend the activity to the sender
const exceptions = [ byActor ]
await forwardVideoRelatedActivity(activity, undefined, exceptions, video)

View file

@ -4,6 +4,7 @@ import * as chokidar from 'chokidar'
import { FfmpegCommand } from 'fluent-ffmpeg'
import { ensureDir, stat } from 'fs-extra'
import { basename } from 'path'
import { isTestInstance } from '@server/helpers/core-utils'
import {
computeResolutionsToTranscode,
getVideoFileFPS,
@ -451,7 +452,7 @@ class LiveManager {
private async updateLiveViews () {
if (!this.isRunning()) return
logger.info('Updating live video views.')
if (!isTestInstance()) logger.info('Updating live video views.')
for (const videoId of this.watchersPerVideo.keys()) {
const notBefore = new Date().getTime() - VIEW_LIFETIME.LIVE