Compare commits

..

No commits in common. "7f4611feefea8662210b16a705241afa3d31f075" and "447ae08e2498eda27e66df8c638eefc695cb840d" have entirely different histories.

4 changed files with 39 additions and 26 deletions

22
overlays/neovim.nix Normal file
View File

@ -0,0 +1,22 @@
self: super:
{
neovim = super.neovim.override {
viAlias = true;
vimAlias = true;
configure = {
customRC = ''
set shiftwidth=2
set softtabstop=2
set expandtab
set background=dark
'';
packages.myVimPackage = with super.vimPlugins; {
start = [
vim-startify airline sensible
polyglot ale fugitive
];
opt = [ ];
};
};
};
}

6
overlays/sudo.nix Normal file
View File

@ -0,0 +1,6 @@
self: super:
{
sudo = super.sudo.override {
withInsults = true;
};
}

View File

@ -161,10 +161,10 @@ in
alias = "/var/www/site-musique/media/";
};
};
"maxspiegel.fr" = base { "/" = { root = "/run/python-ci/nyanloutre/site-max"; }; };
"maxspiegel.fr" = base { "/" = { root = "/run/python-ci/nyanloutre/site-max"; };
"stream.nyanlout.re" = base {
"/" = {
root = "/var/www/hls/";
root = "/var/www/hls/"
extraConfig = ''
add_header Cache-Control no-cache;
add_header Access-Control-Allow-Origin *;
@ -185,9 +185,7 @@ in
"ci.nyanlout.re" = simpleReverse 52350;
"gitea.nyanlout.re" = simpleReverse config.services.gitea.httpPort;
};
appendConfig = let
rootLocation = config.services.nginx.virtualHosts."stream.nyanlout.re".locations."/".root;
in ''
appendConfig = ''
rtmp {
server {
listen 1935;
@ -198,14 +196,14 @@ in
exec_push ${pkgs.ffmpeg}/bin/ffmpeg -i rtmp://localhost/$app/$name -async 1 -vsync -1
-c:v libx264 -c:a aac -b:v 768k -b:a 96k -vf "scale=720:trunc(ow/a/2)*2" -tune zerolatency -preset ultrafast -crf 28 -f flv rtmp://localhost/show/$name_mid
-c:v libx264 -c:a aac -b:v 1024k -b:a 128k -vf "scale=960:trunc(ow/a/2)*2" -tune zerolatency -preset ultrafast -crf 28 -f flv rtmp://localhost/show/$name_high
-c copy -f flv rtmp://localhost/show/$name_src 2>>${rootLocation}/ffmpeg-$name.log;
-c copy -f flv rtmp://localhost/show/$name_src 2>>${config.services.nginx.virtualHosts."stream.nyanlout.re".root}/ffmpeg-$name.log;
}
application show {
live on;
hls on;
hls_path ${rootLocation};
hls_path ${config.services.nginx.virtualHosts."stream.nyanlout.re".root};
hls_fragment 3s;
hls_playlist_length 60s;

View File

@ -4,27 +4,14 @@
time.timeZone = "Europe/Paris";
nixpkgs.overlays = [
(import ../overlays/sudo.nix)
(import ../overlays/neovim.nix)
];
environment.systemPackages = with pkgs; [
# Editeurs
(neovim.override {
viAlias = true;
vimAlias = true;
configure = {
customRC = ''
set shiftwidth=2
set softtabstop=2
set expandtab
set background=dark
'';
packages.myVimPackage = with pkgs.vimPlugins; {
start = [
vim-startify airline sensible
polyglot ale fugitive
];
opt = [ ];
};
};
})
neovim
# Gestionnaires de version
gitFull