280 current 2025-10-11 05:36:52 25.05.20251006.20c4598 6.12.50 *

This commit is contained in:
2025-10-11 05:40:29 -05:00
parent 6a60ce6b85
commit afccaa5886
2 changed files with 74 additions and 73 deletions

View File

@@ -1,6 +1,6 @@
# flake for blakes nixos config # flake for blakes nixos config
# define new devices in outputs # define new devices in outputs
# generation: 279 current 2025-10-11 05:35:16 25.05.20251006.20c4598 6.12.50 * # generation: 280 current 2025-10-11 05:36:52 25.05.20251006.20c4598 6.12.50 *
{ {
description = "blakes nix config"; description = "blakes nix config";
inputs = { inputs = {

View File

@@ -55,75 +55,53 @@ in
extraGroups = []; extraGroups = [];
}; };
virtualisation.oci-containers.containers = {
homeassistant = {
image = "homeassistant/home-assistant:stable";
autoStart = true;
extraOptions = [
"--pull=newer"
];
volumes = [
"${cfg.data_dir}:/config"
];
ports = [
"0.0.0.0:7704:8123"
"0.0.0.0:4141:4141"
];
environment = {
TZ = homelab.tz;
PUID = toString config.users.users.${service}.uid;
PGID = toString config.users.groups.${service}.gid;
};
};
};
# here lies my tough, and I mean fucking tough, swing at # here lies my tough, and I mean fucking tough, swing at
# getting this to work bare metal, ggs ill see you again # getting this to work bare metal, ggs ill see you again
# - didnt take long
# -------------------------------------------------------------------------------- # --------------------------------------------------------------------------------
# # enable the ${service} service # enable the ${service} service
# services.${service} = { services.${nixservice} = {
# enable = true; enable = true;
# package = inputs.nixpkgs-unstable.legacyPackages.${pkgs.system}.home-assistant; package = inputs.nixpkgs-unstable.legacyPackages.${pkgs.system}.home-assistant;
# extraComponents = [ extraComponents = [
# # required for onboarding # required for onboarding
# "analytics" "analytics"
# "google_translate" "google_translate"
# "met" "met"
# "radio_browser" "radio_browser"
# "shopping_list" "shopping_list"
# "isal" "isal"
# "default_config" "default_config"
# "mqtt" "mqtt"
# ]; ];
# extraPackages = python3Packages: with python3Packages; [ extraPackages = python3Packages: with python3Packages; [
# psycopg2 psycopg2
# universal-silabs-flasher universal-silabs-flasher
# getmac getmac
# zha zha
# ha-silabs-firmware-client ha-silabs-firmware-client
# paho-mqtt paho-mqtt
# aiomqtt aiomqtt
# aiounifi aiounifi
# ]; ];
# # imperative config # imperative config
# config = null; config = null;
# lovelaceConfig = null; lovelaceConfig = null;
# configDir = cfg.data_dir; configDir = cfg.data_dir;
# # declartive poggers! # declartive poggers!
## config = { # config = {
## # Includes dependencies for a basic setup # # Includes dependencies for a basic setup
## default_config = {}; # default_config = {};
## }; # };
};
# override umask to make permissions work out
# systemd.services.${service}.serviceConfig = {
UMask = lib.mkForce "0007";
User = lib.mkForce ${service};
Group = lib.mkForce ${service};
# }; # };
#
#
# # override umask to make permissions work out
## systemd.services.${service}.serviceConfig = {
## UMask = lib.mkForce "0007";
## User = lib.mkForce ${service};
## Group = lib.mkForce ${service};
## };
# --------------------------------------------------------------------------------
# open firewall # open firewall
networking.firewall.allowedTCPPorts = [ cfg.port 8123 ]; networking.firewall.allowedTCPPorts = [ cfg.port 8123 ];
@@ -161,14 +139,37 @@ in
}; };
}; };
# sops.secrets = {
# "${service}_" = {
# owner = "${service}";
# group = "${service}";
# };
# };
# add to backups # add to backups
modules.system.backups.paths = lib.mkIf cfg.backup [ cfg.data_dir ]; modules.system.backups.paths = lib.mkIf cfg.backup [ cfg.data_dir ];
}; };
} }
# still suss as fuck bro man fuck
# virtualisation.oci-containers.containers = {
# homeassistant = {
# image = "homeassistant/home-assistant:stable";
# autoStart = true;
# extraOptions = [
# "--pull=newer"
# ];
# volumes = [
# "${cfg.data_dir}:/config"
# ];
# ports = [
# "0.0.0.0:7704:8123"
# "0.0.0.0:4141:4141"
# ];
# environment = {
# TZ = homelab.tz;
# PUID = toString config.users.users.${service}.uid;
# PGID = toString config.users.groups.${service}.gid;
# };
# };
# };