30 lines
655 B
Nix
30 lines
655 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
with lib;
|
|
{
|
|
virtualisation = {
|
|
podman = {
|
|
enable = true;
|
|
enableNvidia = true;
|
|
};
|
|
oci-containers = {
|
|
# backend = "podman";
|
|
containers = {
|
|
localai = {
|
|
image = [ "quay.io/go-skynet/local-ai:v2.0.0-cublas-cuda11-ffmpeg" ];
|
|
autoStart = true;
|
|
ports = [ "7890:8080" ];
|
|
volumes = [ "/home/chris/localai/models:/models" ];
|
|
environment = {
|
|
THREADS = "2";
|
|
MODELS_PATH = "/models";
|
|
DEBUG = true;
|
|
REBUILD = true;
|
|
BUILD_TYPE = "cublas";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
}
|