From 517094a3f8407466c37236becdb522f51becf248 Mon Sep 17 00:00:00 2001 From: Dmitriy Pleshevskiy Date: Fri, 31 Mar 2023 17:39:02 +0300 Subject: [PATCH] host: use unstable ipfs move ipfs to shared config --- nixos/hosts/asus-gl553vd/default.nix | 10 ++-------- nixos/hosts/home/default.nix | 10 ++-------- nixos/shared/ipfs.nix | 12 ++++++++++++ 3 files changed, 16 insertions(+), 16 deletions(-) create mode 100644 nixos/shared/ipfs.nix diff --git a/nixos/hosts/asus-gl553vd/default.nix b/nixos/hosts/asus-gl553vd/default.nix index e5ed1e1..ba1d5f0 100644 --- a/nixos/hosts/asus-gl553vd/default.nix +++ b/nixos/hosts/asus-gl553vd/default.nix @@ -1,4 +1,4 @@ -{ config, pkgs, lib, ... }: +{ config, pkgs, ... }: { imports = [ @@ -11,6 +11,7 @@ ../../shared/gnupg.nix ../../shared/garbage-collector.nix ../../shared/networking.secret.nix + ../../shared/ipfs.nix ]; # Use latest kernel @@ -58,13 +59,6 @@ # Enable the Docker virtualisation.docker.enable = true; - # Enable ipfs - services.kubo = { - enable = true; - localDiscovery = true; - enableGC = true; - }; - # Additional nix configs local.nix.enableMyRegistry = true; diff --git a/nixos/hosts/home/default.nix b/nixos/hosts/home/default.nix index 60ff547..d25cb91 100644 --- a/nixos/hosts/home/default.nix +++ b/nixos/hosts/home/default.nix @@ -1,4 +1,4 @@ -{ config, pkgs, lib, ... }: +{ config, pkgs, ... }: { imports = [ @@ -11,6 +11,7 @@ ../../shared/gnupg.nix ../../shared/garbage-collector.nix ../../shared/networking.secret.nix + ../../shared/ipfs.nix ]; # Configure kernel @@ -83,13 +84,6 @@ # Enable the Docker virtualisation.docker.enable = true; - # Enable ipfs - services.kubo = { - enable = true; - localDiscovery = true; - enableGC = true; - }; - # Additional nix configs local.nix.enableMyRegistry = true; diff --git a/nixos/shared/ipfs.nix b/nixos/shared/ipfs.nix new file mode 100644 index 0000000..d5b2fc0 --- /dev/null +++ b/nixos/shared/ipfs.nix @@ -0,0 +1,12 @@ +{ pkgs, ... }: + +{ + # Enable ipfs + services.kubo = { + enable = true; + localDiscovery = true; + enableGC = true; + # it doesn't work in stable + package = pkgs.unstable.kubo; + }; +}