me like nix
0

Configure Feed

Select the types of activity you want to include in your feed.

1{ 2 pkgs, 3 config, 4 ... 5}: 6 7{ 8 imports = [ 9 # Include the results of the hardware scan. 10 ./hardware-configuration.nix 11 ../common/common.nix 12 ]; 13 14 networking.hostName = "mira"; # Define your hostname. 15 # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. 16 17 # Configure network proxy if necessary 18 # networking.proxy.default = "http://user:password@proxy:port/"; 19 # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; 20 21 # this is like a network devices discovery thing 22 services.avahi = { 23 enable = true; 24 nssmdns4 = true; 25 openFirewall = true; 26 }; 27 28 services.copyparty.enable = true; 29 30 services.openssh = { 31 enable = true; 32 settings = { 33 PasswordAuthentication = false; 34 KbdInteractiveAuthentication = false; 35 PermitRootLogin = "no"; 36 AllowUsers = [ "sean" ]; 37 }; 38 }; 39 40 users.users.sean.openssh.authorizedKeys.keys = [ 41 "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDCIqgZ7kedxo+mOW7YG73Vp3zel3h180y3GKvHtRsXfGlpIIvRDy7pgCBQ4AGXYD4y78URQmFohYSAPqCPOPaWcU2un3XG9KvCzEsHmsbskPonitUmCiKvrKkb6oW4jCBtd7AEtBn+AiajAQFtPZ7NN2Df3AmTypvR6Irg7R+nxnfc9NTIHmGvxSDyWcbb4pguL20sctUSqGL6xGh8q/bqhdOThSimM+z9bEUNxK/5rPhwkNniMrp4pJcUrUiAh5/4DiRFG6KT+oeg+/myoz/Z1sPvAs7u/8JDQI4RshRD8Hu0oTkRBN6Hxj478q2SXbeBUZlD6IdjP3RhGpmSecoDdtWqKbpuV3eVRtQtba3KL86GBeV/bugaOdJ1Aud+1SOFJreAAuvxzMMKT+cdQZk6oOPP148DA/No+mDm/2S43lcdCXh79wA6YRAmKQ8jmZxTCtPutrvuZK1rguvvUlEoG/vhdNHh7eDa4Td07V6bjCRPUl8qk/e4M0E3pwsTlZc=" 42 ]; 43 44 # List services that you want to enable: 45 services.flaresolverr.enable = true; 46 nixarr = { 47 enable = true; 48 mediaDir = "/mnt/storage1/nixarr/media"; 49 vpn = { 50 enable = true; 51 wgConf = "/mnt/storage1/nixarr/wireguard.conf"; 52 }; 53 54 jellyfin = { 55 enable = true; 56 openFirewall = true; 57 }; 58 59 transmission = { 60 enable = true; 61 vpn.enable = true; 62 }; 63 sabnzbd = { 64 enable = true; 65 vpn.enable = true; 66 openFirewall = true; 67 }; 68 69 prowlarr.enable = true; 70 radarr.enable = true; 71 sonarr.enable = true; 72 jellyseerr = { 73 enable = true; 74 openFirewall = true; 75 }; 76 77 recyclarr = { 78 enable = true; 79 configuration = { 80 sonarr = { 81 series = { 82 base_url = "http://localhost:8989"; 83 api_key = "!env_var SONARR_API_KEY"; 84 quality_definition = { 85 type = "series"; 86 }; 87 delete_old_custom_formats = true; 88 custom_formats = [ 89 { 90 trash_ids = [ 91 "85c61753df5da1fb2aab6f2a47426b09" # BR-DISK 92 "9c11cd3f07101cdba90a2d81cf0e56b4" # LQ 93 ]; 94 assign_scores_to = [ 95 { 96 name = "WEB-DL (1080p)"; 97 score = -10000; 98 } 99 ]; 100 } 101 ]; 102 }; 103 }; 104 radarr = { 105 movies = { 106 base_url = "http://localhost:7878"; 107 api_key = "!env_var RADARR_API_KEY"; 108 quality_definition = { 109 type = "movie"; 110 }; 111 delete_old_custom_formats = true; 112 custom_formats = [ 113 { 114 trash_ids = [ 115 "570bc9ebecd92723d2d21500f4be314c" # Remaster 116 "eca37840c13c6ef2dd0262b141a5482f" # 4K Remaster 117 ]; 118 assign_scores_to = [ 119 { 120 name = "HD Bluray + WEB"; 121 score = 25; 122 } 123 ]; 124 } 125 ]; 126 }; 127 }; 128 }; 129 }; 130 }; 131 132 # MQTT broker for Home Assistant (Tasmota devices) 133 services.mosquitto = { 134 enable = true; 135 listeners = [ 136 { 137 acl = [ "pattern readwrite #" ]; 138 omitPasswordAuth = true; 139 settings.allow_anonymous = true; 140 } 141 ]; 142 }; 143 144 # Home Assistant service 145 services.home-assistant = { 146 enable = true; 147 extraComponents = [ 148 "esphome" 149 "met" 150 "radio_browser" 151 "homekit" 152 "homekit_controller" 153 "isal" 154 "mqtt" 155 "tasmota" 156 "wiz" 157 "google_translate" # TTS - was missing gtts module 158 "ecobee" # Was missing pyecobee module 159 "ibeacon" # Was missing ibeacon_ble module 160 "go2rtc" # Camera streaming 161 "generic" # Generic camera integration 162 ]; 163 config = { 164 homeassistant = { 165 time_zone = "America/Toronto"; 166 }; 167 default_config = { }; 168 zeroconf = { }; 169 # MQTT configuration - broker must be set up via UI 170 mqtt = { }; 171 # Automations 172 automation = [ 173 { 174 id = "1761448856909"; 175 alias = "Lower heat at night"; 176 trigger = [ 177 { 178 platform = "time"; 179 at = "23:00:00"; 180 } 181 ]; 182 condition = [ ]; 183 action = [ 184 { 185 action = "climate.set_temperature"; 186 target.device_id = "bfe22d32a4532f8ae991d6daffb48267"; 187 data = { 188 hvac_mode = "heat"; 189 temperature = 18; 190 }; 191 } 192 ]; 193 mode = "single"; 194 } 195 { 196 id = "1766200000001"; 197 alias = "Raise heat in morning"; 198 trigger = [ 199 { 200 platform = "time"; 201 at = "06:00:00"; 202 } 203 ]; 204 condition = [ ]; 205 action = [ 206 { 207 action = "climate.set_temperature"; 208 target.device_id = "bfe22d32a4532f8ae991d6daffb48267"; 209 data = { 210 hvac_mode = "heat"; 211 temperature = 21; 212 }; 213 } 214 ]; 215 mode = "single"; 216 } 217 { 218 id = "1766153071796"; 219 alias = "Close Garage Door"; 220 trigger = [ 221 { 222 platform = "device"; 223 device_id = "d8dedd8cd0ce1488d9830c455bb0a761"; 224 domain = "cover"; 225 entity_id = "cf36763543169888aa106b1acb02ad72"; 226 type = "opened"; 227 for = { 228 hours = 0; 229 minutes = 10; 230 seconds = 0; 231 }; 232 } 233 ]; 234 condition = [ ]; 235 action = [ 236 { 237 device_id = "d8dedd8cd0ce1488d9830c455bb0a761"; 238 domain = "cover"; 239 entity_id = "cf36763543169888aa106b1acb02ad72"; 240 type = "close"; 241 } 242 ]; 243 mode = "single"; 244 } 245 ]; 246 }; 247 }; 248 249 # Enable the OpenSSH daemon. 250 # services.openssh.enable = true; 251 252 security.pam.loginLimits = [ 253 { 254 domain = "*"; 255 type = "soft"; 256 item = "nofile"; 257 value = "8192"; 258 } 259 ]; 260 261 # Open ports in the firewall. 262 networking.firewall.allowedTCPPorts = [ 263 8096 # jellyfin 264 5055 # jellyseer 265 3000 # vite dev port 266 1883 # MQTT for Tasmota devices 267 2300 # trmnl 268 config.services.home-assistant.config.http.server_port 269 ]; 270 networking.firewall.allowedUDPPorts = [ 271 ]; 272 # networking.firewall.enable = false; 273 274 # This value determines the NixOS release from which the default 275 # settings for stateful data, like file locations and database versions 276 # on your system were taken. It‘s perfectly fine and recommended to leave 277 # this value at the release version of the first install of this system. 278 # Before changing this value read the documentation for this option 279 # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). 280 system.stateVersion = "25.05"; # Did you read the comment? 281 282}