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 ]; 161 config = { 162 homeassistant = { 163 time_zone = "America/Toronto"; 164 }; 165 default_config = { }; 166 zeroconf = { }; 167 # MQTT configuration - broker must be set up via UI 168 mqtt = { }; 169 # Automations 170 automation = [ 171 { 172 id = "1761448856909"; 173 alias = "Turn off heat"; 174 trigger = [ 175 { 176 platform = "time"; 177 at = "23:00:00"; 178 } 179 ]; 180 condition = [ ]; 181 action = [ 182 { 183 action = "climate.turn_off"; 184 target.device_id = "bfe22d32a4532f8ae991d6daffb48267"; 185 } 186 ]; 187 mode = "single"; 188 } 189 { 190 id = "1766200000001"; 191 alias = "Turn on heat"; 192 trigger = [ 193 { 194 platform = "time"; 195 at = "06:00:00"; 196 } 197 ]; 198 condition = [ ]; 199 action = [ 200 { 201 action = "climate.set_hvac_mode"; 202 target.device_id = "bfe22d32a4532f8ae991d6daffb48267"; 203 data.hvac_mode = "heat"; 204 } 205 ]; 206 mode = "single"; 207 } 208 { 209 id = "1766153071796"; 210 alias = "Close Garage Door"; 211 trigger = [ 212 { 213 platform = "device"; 214 device_id = "d8dedd8cd0ce1488d9830c455bb0a761"; 215 domain = "cover"; 216 entity_id = "cf36763543169888aa106b1acb02ad72"; 217 type = "opened"; 218 for = { 219 hours = 0; 220 minutes = 10; 221 seconds = 0; 222 }; 223 } 224 ]; 225 condition = [ ]; 226 action = [ 227 { 228 device_id = "d8dedd8cd0ce1488d9830c455bb0a761"; 229 domain = "cover"; 230 entity_id = "cf36763543169888aa106b1acb02ad72"; 231 type = "close"; 232 } 233 ]; 234 mode = "single"; 235 } 236 ]; 237 }; 238 }; 239 240 # Enable the OpenSSH daemon. 241 # services.openssh.enable = true; 242 243 security.pam.loginLimits = [ 244 { 245 domain = "*"; 246 type = "soft"; 247 item = "nofile"; 248 value = "8192"; 249 } 250 ]; 251 252 # Open ports in the firewall. 253 networking.firewall.allowedTCPPorts = [ 254 8096 # jellyfin 255 5055 # jellyseer 256 3000 # vite dev port 257 1883 # MQTT for Tasmota devices 258 2300 # trmnl 259 config.services.home-assistant.config.http.server_port 260 ]; 261 networking.firewall.allowedUDPPorts = [ 262 ]; 263 # networking.firewall.enable = false; 264 265 # This value determines the NixOS release from which the default 266 # settings for stateful data, like file locations and database versions 267 # on your system were taken. It‘s perfectly fine and recommended to leave 268 # this value at the release version of the first install of this system. 269 # Before changing this value read the documentation for this option 270 # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). 271 system.stateVersion = "25.05"; # Did you read the comment? 272 273}