nix-configs/nixos-modules/docker-zwave.nix

44 lines
1.2 KiB
Nix
Raw Normal View History

2024-10-01 12:52:39 -04:00
{ inputs, pkgs, ... }:
{
virtualisation = {
containers.enable = true;
podman.enable = true;
oci-containers.containers = {
zwave-js-ui = {
2024-11-02 20:41:30 -04:00
image = "zwavejs/zwave-js-ui:latest";
# image = "my-zwave-js-ui:latest";
# imageFile = pkgs.dockerTools.buildLayeredImage {
# name = "my-zwave-js-ui";
# tag = "latest";
# contents = [
# pkgs.cacert
# pkgs.busybox
# ];
# config = {
# Cmd = [ "${inputs.self.packages.${pkgs.stdenv.system}.zwave-js-ui}/bin/zwave-js-ui" ];
# Env = [
# "STORE_DIR=/usr/src/app/store"
# "ZWAVEJS_EXTERNAL_CONFIG=/usr/src/app/store/.config-db"
# "SSL_CERT_FILE=${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt"
# ];
# };
# };
2024-10-01 12:52:39 -04:00
volumes = [ "zwave-config:/usr/src/app/store" ];
environment = {
TZ = "America/New_York";
};
labels = {
swag = "enable";
swag_url = "zwave.icanttype.org";
swag_port = "8091";
};
extraOptions = [
"--network=www"
2024-11-02 20:41:30 -04:00
"--pull=newer"
2024-10-01 12:52:39 -04:00
"--device=/dev/ttyACM0:/dev/zwave"
];
};
};
};
}