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