refactor(treewide): format with alejandra

This commit is contained in:
ooks-io 2024-07-29 15:00:38 +12:00
parent 7fefb94400
commit 61cef505da
216 changed files with 5995 additions and 3969 deletions

View file

@ -1,11 +1,11 @@
{ lib, config, ... }:
let
{
lib,
config,
...
}: let
inherit (lib) mkIf;
host = config.ooknet.host;
in
{
in {
imports = [
./firewall.nix
./tools.nix

View file

@ -1,11 +1,11 @@
{ lib, config, ... }:
let
{
lib,
config,
...
}: let
inherit (lib) mkIf;
host = config.ooknet.host;
in
{
in {
config = mkIf (host.type != "phone") {
networking.firewall = {
enable = true;

View file

@ -1,18 +1,18 @@
{ lib, config, ... }:
let
{
lib,
config,
...
}: let
inherit (lib) mkIf;
host = config.ooknet.host;
in
{
in {
config = mkIf (host.type != "phone") {
services.resolved = {
enable = true;
fallbackDns = ["9.9.9.9"];
# allow-downgrade is vulnerable to downgrade attacks
extraConfig = ''
DNSOverTLS=yes # or allow-downgrade
DNSOverTLS=yes # or allow-downgrade
'';
};
};

View file

@ -1,11 +1,11 @@
{ lib, config, ... }:
let
{
lib,
config,
...
}: let
inherit (lib) mkIf mkDefault;
host = config.ooknet.host;
in
{
in {
config = mkIf (host.type != "phone") {
services.openssh = {
enable = true;

View file

@ -1,12 +1,13 @@
{ lib, config, pkgs, ... }:
let
{
lib,
config,
pkgs,
...
}: let
cfg = config.ooknet.host.networking.tailscale;
inherit (config.services) tailscale;
inherit (lib) mkIf mkDefault mkBefore;
in
{
in {
config = mkIf cfg.enable {
services.tailscale = {
enable = true;
@ -29,7 +30,7 @@ in
};
systemd.network.wait-online.ignoredInterfaces = ["${tailscale.interfaceName}"];
environment.systemPackages = [ pkgs.tailscale ];
environment.systemPackages = [pkgs.tailscale];
# disable tailscale logging
systemd.services.tailscaled.serviceConfig.Environment = mkBefore ["TS_NO_LOGS_NO_SUPPORT"];

View file

@ -1,11 +1,11 @@
{ lib, config, ... }:
let
{
lib,
config,
...
}: let
inherit (lib) mkIf;
host = config.ooknet.host;
in
{
in {
# nyx module
config = mkIf (host.type != "phone") {
boot = {

View file

@ -1,6 +1,4 @@
{ pkgs, ... }:
{
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
traceroute
mtr