Adjust nginx proc count based on available CPUs (#11653)

* Restrict nginx to 4 processes if more are available

* Fix bash

* Different sed structure

* Limit ffmpeg thread counts for secondary ffmpeg processes

* Add up / down keyboard shortcut
This commit is contained in:
Nicolas Mowen
2024-05-30 11:34:01 -06:00
committed by GitHub
parent 402c16e7df
commit 142641b387
5 changed files with 37 additions and 2 deletions

View File

@@ -139,6 +139,11 @@ export default function VideoControls({
const onKeyboardShortcut = useCallback(
(key: string, down: boolean, repeat: boolean) => {
switch (key) {
case "ArrowDown":
if (down) {
onSeek(-1);
}
break;
case "ArrowLeft":
if (down) {
onSeek(-10);
@@ -149,6 +154,11 @@ export default function VideoControls({
onSeek(10);
}
break;
case "ArrowUp":
if (down) {
onSeek(1);
}
break;
case "f":
if (setFullscreen && down && !repeat) {
setFullscreen(!fullscreen);
@@ -171,7 +181,9 @@ export default function VideoControls({
[video, isPlaying, fullscreen, setFullscreen, onSeek],
);
useKeyboardListener(
hotKeys ? ["ArrowLeft", "ArrowRight", "f", "m", " "] : [],
hotKeys
? ["ArrowDown", "ArrowLeft", "ArrowRight", "ArrowUp", "f", "m", " "]
: [],
onKeyboardShortcut,
);