home

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 2a57c76e68adf911a021fabc31a8e84adbac9fc1
parent c9c081423d8ec45969953c6253d9348954d0234f
Author: Vincent Demeester <vincent@sbr.pm>
Date:   Thu,  1 Nov 2018 16:21:51 +0100

profiles: add docker profile

Signed-off-by: Vincent Demeester <vincent@sbr.pm>

Diffstat:
Mmodules/module-list.nix | 1+
Amodules/profiles/docker.nix | 32++++++++++++++++++++++++++++++++
Mshikoku.nix | 1+
Mwakasu.nix | 4+---
4 files changed, 35 insertions(+), 3 deletions(-)

diff --git a/modules/module-list.nix b/modules/module-list.nix @@ -11,6 +11,7 @@ ./profiles/dev.js.nix ./profiles/dev.python.nix ./profiles/dev.rust.nix + ./profiles/docker.nix ./profiles/emacs.nix ./profiles/fish.nix ./profiles/gaming.nix diff --git a/modules/profiles/docker.nix b/modules/profiles/docker.nix @@ -0,0 +1,32 @@ +{ config, lib, pkgs, ... }: + +with lib; +let + cfg = config.profiles.docker; +in +{ + options = { + profiles.docker = { + enable = mkOption { + default = false; + description = "Enable docker profile"; + type = types.bool; + }; + }; + }; + config = mkIf cfg.enable (mkMerge [ + { + home.packages = with pkgs; [ + docker + docker-machine + docker-machine-kvm + docker-machine-kvm2 + ]; + } + (mkIf config.profiles.fish.enable { + xdg.configFile."fish/conf.d/docker.fish".text = '' + set -gx DOCKER_BUILDKIT 1 + ''; + }) + ]); +} diff --git a/shikoku.nix b/shikoku.nix @@ -16,6 +16,7 @@ python.enable = true; rust.enable = true; }; + profiles.docker.enable = true; programs.vscode.enable = true; programs.podman.enable = true; xdg.configFile."fish/conf.d/docker.fish".text = '' diff --git a/wakasu.nix b/wakasu.nix @@ -15,11 +15,9 @@ python.enable = true; rust.enable = true; }; + profiles.docker.enable = true; programs.vscode.enable = true; programs.podman.enable = true; - xdg.configFile."fish/conf.d/docker.fish".text = '' - set -gx DOCKER_BUILDKIT 1 - ''; home.packages = with pkgs; [ google-chrome obs-studio