mirror of
https://github.com/nmasur/dotfiles
synced 2025-07-06 02:40:14 +00:00
remove inputs
This commit is contained in:
29
platforms/home-manager/modules/nixpkgs.nix
Normal file
29
platforms/home-manager/modules/nixpkgs.nix
Normal file
@ -0,0 +1,29 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
|
||||
options = {
|
||||
allowUnfreePackages = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
description = "List of unfree packages to allow.";
|
||||
default = [ ];
|
||||
};
|
||||
allowInsecurePackages = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
description = "List of insecure packages to allow.";
|
||||
default = [ ];
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
|
||||
# Allow specified unfree packages (identified elsewhere)
|
||||
# Retrieves package object based on string name
|
||||
nixpkgs.config.allowUnfreePredicate =
|
||||
pkg: builtins.elem (lib.getName pkg) config.allowUnfreePackages;
|
||||
|
||||
# Allow specified insecure packages (identified elsewhere)
|
||||
nixpkgs.config.permittedInsecurePackages = config.allowInsecurePackages;
|
||||
|
||||
};
|
||||
|
||||
}
|
@ -14,7 +14,7 @@ in
|
||||
options.nmasur.presets.programs._1password.enable = lib.mkEnableOption "1Password password manager";
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
unfreePackages = [
|
||||
allowUnfreePackages = [
|
||||
"1password"
|
||||
"_1password-gui"
|
||||
"1password-cli"
|
||||
|
@ -14,7 +14,7 @@ in
|
||||
options.nmasur.presets.programs.discord.enable = lib.mkEnableOption "Discord chat";
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
unfreePackages = [ "discord" ];
|
||||
allowUnfreePackages = [ "discord" ];
|
||||
home.packages = [ pkgs.discord ];
|
||||
xdg.configFile."discord/settings.json".text = pkgs.formats.json {
|
||||
BACKGROUND_COLOR = "#202225";
|
||||
|
@ -17,7 +17,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
||||
unfreePackages = [
|
||||
allowUnfreePackages = [
|
||||
"okta-browser-plugin"
|
||||
];
|
||||
|
||||
|
@ -15,7 +15,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
||||
unfreePackages = [ "terraform" ];
|
||||
allowUnfreePackages = [ "terraform" ];
|
||||
|
||||
programs.fish.shellAbbrs = {
|
||||
te = "terraform";
|
||||
|
@ -15,7 +15,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
||||
unfreePackages = [
|
||||
allowUnfreePackages = [
|
||||
"vault-bin"
|
||||
# "teams"
|
||||
];
|
||||
|
@ -32,5 +32,18 @@ in
|
||||
"/opt/homebrew/opt/trash/bin"
|
||||
];
|
||||
|
||||
# Include home-manager config in nix-darwin
|
||||
home-manager = {
|
||||
sharedModules = [ ../../../../home-manager ];
|
||||
|
||||
# Use the system-level nixpkgs instead of Home Manager's
|
||||
useGlobalPkgs = lib.mkDefault true;
|
||||
|
||||
# Install packages to /etc/profiles instead of ~/.nix-profile, useful when
|
||||
# using multiple profiles for one user
|
||||
useUserPackages = lib.mkDefault true;
|
||||
|
||||
};
|
||||
|
||||
};
|
||||
}
|
||||
|
29
platforms/nixos/modules/nixpkgs.nix
Normal file
29
platforms/nixos/modules/nixpkgs.nix
Normal file
@ -0,0 +1,29 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
|
||||
options = {
|
||||
allowUnfreePackages = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
description = "List of unfree packages to allow.";
|
||||
default = [ ];
|
||||
};
|
||||
allowInsecurePackages = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
description = "List of insecure packages to allow.";
|
||||
default = [ ];
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
|
||||
# Allow specified unfree packages (identified elsewhere)
|
||||
# Retrieves package object based on string name
|
||||
nixpkgs.config.allowUnfreePredicate =
|
||||
pkg: builtins.elem (lib.getName pkg) config.allowUnfreePackages;
|
||||
|
||||
# Allow specified insecure packages (identified elsewhere)
|
||||
nixpkgs.config.permittedInsecurePackages = config.allowInsecurePackages;
|
||||
|
||||
};
|
||||
|
||||
}
|
@ -14,7 +14,7 @@ in
|
||||
options.nmasur.presets.programs.dwarf-fortress.enable = lib.mkEnableOption "Dwarf Fortress";
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
unfreePackages = [
|
||||
allowUnfreePackages = [
|
||||
"dwarf-fortress"
|
||||
"phoebus-theme"
|
||||
];
|
||||
|
@ -15,7 +15,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
hardware.steam-hardware.enable = true;
|
||||
unfreePackages = [
|
||||
allowUnfreePackages = [
|
||||
"steam"
|
||||
"steam-original"
|
||||
"steamcmd"
|
||||
|
@ -88,7 +88,7 @@ in
|
||||
# Allows shared group to read/write the sabnzbd directory
|
||||
users.users.sabnzbd.homeMode = "0770";
|
||||
|
||||
unfreePackages = [ "unrar" ]; # Required as a dependency for sabnzbd
|
||||
allowUnfreePackages = [ "unrar" ]; # Required as a dependency for sabnzbd
|
||||
|
||||
# Requires updating the base_url config value in each service
|
||||
# If you try to rewrite the URL, the service won't redirect properly
|
||||
|
@ -20,7 +20,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
||||
unfreePackages = [ "minecraft-server" ];
|
||||
allowUnfreePackages = [ "minecraft-server" ];
|
||||
|
||||
services.minecraft-server = {
|
||||
eula = true;
|
||||
|
@ -14,7 +14,7 @@ in
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
||||
unfreePackages = [ "n8n" ];
|
||||
allowUnfreePackages = [ "n8n" ];
|
||||
|
||||
services.n8n = {
|
||||
webhookUrl = "https://${hostnames.n8n}";
|
||||
|
Reference in New Issue
Block a user