PlaylistsCommand,
ServicesCommand,
StreamingPlaylistsCommand,
+ VideoEditorCommand,
VideosCommand
} from '../videos'
import { CommentsCommand } from '../videos/comments-command'
login?: LoginCommand
users?: UsersCommand
objectStorage?: ObjectStorageCommand
+ videoEditor?: VideoEditorCommand
videos?: VideosCommand
constructor (options: { serverNumber: number } | { url: string }) {
Object.assign(env, options.env)
}
+ const execArgv = options.nodeArgs || []
+ // FIXME: too slow :/
+ // execArgv.push('--enable-source-maps')
+
const forkOptions = {
silent: true,
env,
detached: true,
- execArgv: options.nodeArgs || []
+ execArgv
}
+ const peertubeArgs = options.peertubeArgs || []
+
return new Promise<void>((res, rej) => {
const self = this
let aggregatedLogs = ''
- this.app = fork(join(root(), 'dist', 'server.js'), options.peertubeArgs || [], forkOptions)
+ this.app = fork(join(root(), 'dist', 'server.js'), peertubeArgs, forkOptions)
const onPeerTubeExit = () => rej(new Error('Process exited:\n' + aggregatedLogs))
const onParentExit = () => {
this.users = new UsersCommand(this)
this.videos = new VideosCommand(this)
this.objectStorage = new ObjectStorageCommand(this)
+ this.videoEditor = new VideoEditorCommand(this)
}
}