home->nixos: restructure sway
This commit is contained in:
parent
ab01192de5
commit
86e6bd6184
|
@ -1,9 +1,5 @@
|
||||||
{pkgs, ...}:
|
{pkgs, ...}:
|
||||||
{
|
{
|
||||||
home.sessionVariables = {
|
|
||||||
EDITOR = "nvim";
|
|
||||||
};
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
python3
|
python3
|
||||||
killall
|
killall
|
||||||
|
|
|
@ -7,23 +7,23 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
sway
|
# sway
|
||||||
alacritty
|
# alacritty
|
||||||
swayidle
|
# swayidle
|
||||||
swaylock-effects
|
# swaylock-effects
|
||||||
mako
|
# mako
|
||||||
wl-clipboard
|
# wl-clipboard
|
||||||
xdg-desktop-portal-wlr
|
#- xdg-desktop-portal-wlr
|
||||||
bemenu
|
# bemenu
|
||||||
i3blocks
|
# i3blocks
|
||||||
acpi
|
# acpi
|
||||||
lm_sensors
|
# lm_sensors
|
||||||
kdeconnect
|
# ponymix
|
||||||
ponymix
|
# brightnessctl
|
||||||
brightnessctl
|
# gammastep
|
||||||
#gammastep
|
# grim
|
||||||
grim
|
# slurp
|
||||||
slurp
|
# kdeconnect
|
||||||
];
|
];
|
||||||
|
|
||||||
wayland.windowManager.sway =
|
wayland.windowManager.sway =
|
||||||
|
@ -316,6 +316,7 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# use nixos's ....
|
||||||
# from programs.sway:
|
# from programs.sway:
|
||||||
# xdg.portal.enable = true;
|
# xdg.portal.enable = true;
|
||||||
# xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-wlr ];
|
# xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-wlr ];
|
||||||
|
|
|
@ -3,33 +3,32 @@
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
imports = [
|
||||||
[
|
./hardware-configuration.nix
|
||||||
./hardware-configuration.nix
|
./repo/default-hardware.nix
|
||||||
./repo/default.nix
|
./repo/desktop-sway.nix
|
||||||
./repo/desktop.nix
|
./repo/users.nix
|
||||||
./repo/genofire.nix
|
];
|
||||||
];
|
|
||||||
|
|
||||||
system.stateVersion = "21.05";
|
system.stateVersion = "21.05";
|
||||||
|
system.autoUpgrade.channel = "//nixos.org/channels/nixos-unstable";
|
||||||
|
|
||||||
# boot
|
# boot
|
||||||
boot.zfs.requestEncryptionCredentials = []; # list -> default: true - always request for password
|
boot.zfs.requestEncryptionCredentials = []; # list -> default: true - always request for password
|
||||||
|
|
||||||
# --------
|
# --------
|
||||||
# specifical this maschine:
|
# specifical this maschine:
|
||||||
# --------
|
# --------
|
||||||
|
|
||||||
networking.hostId = "6a465f93"; # zfs needed
|
networking.hostId = "/etc/machine-id"; # zfs needed
|
||||||
networking.hostName = "fireEmerald"; # Define your hostname.
|
networking.hostName = "nixos"; # Define your hostname.
|
||||||
# cryptsetup
|
# cryptsetup
|
||||||
# boot.initrd.luks.enable = true;
|
# boot.initrd.luks.enable = true;
|
||||||
boot.initrd.luks.devices = {
|
boot.initrd.luks.devices = {
|
||||||
"croot" = {
|
"croot" = {
|
||||||
device = "/dev/disk/by-uuid/e75385e9-b733-49d4-91fd-6ac2fa821195" ;
|
device = "/dev/disk/by-uuid/e75385e9-b733-49d4-91fd-6ac2fa821195" ;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
{ config, pkgs, ... }:
|
||||||
|
{
|
||||||
|
imports = [./default.nix];
|
||||||
|
|
||||||
|
# boot
|
||||||
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
# zfs
|
||||||
|
boot.initrd.supportedFilesystems = ["zfs"]; # boot from zfs
|
||||||
|
boot.supportedFilesystems = [ "zfs" ];
|
||||||
|
#boot.kernelParams = [ "nohibernate" ];
|
||||||
|
services.zfs.autoScrub.enable = true;
|
||||||
|
|
||||||
|
networking.useNetworkd = true;
|
||||||
|
networking.useDHCP = false;
|
||||||
|
}
|
||||||
|
|
|
@ -5,54 +5,60 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
system.autoUpgrade.enable = true;
|
system.autoUpgrade.enable = true;
|
||||||
|
|
||||||
# boot
|
networking.useDHCP = false;
|
||||||
boot.loader.systemd-boot.enable = true;
|
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
|
||||||
# zfs
|
|
||||||
boot.initrd.supportedFilesystems = ["zfs"]; # boot from zfs
|
|
||||||
boot.supportedFilesystems = [ "zfs" ];
|
|
||||||
#boot.kernelParams = [ "nohibernate" ];
|
|
||||||
services.zfs.autoScrub.enable = true;
|
|
||||||
|
|
||||||
networking.useNetworkd = true;
|
services.openssh = {
|
||||||
networking.useDHCP = false;
|
enable = true;
|
||||||
services.openssh.enable = true;
|
openFirewall = true;
|
||||||
|
ports = [ 1512 ];
|
||||||
|
startWhenNeeded = true;
|
||||||
|
};
|
||||||
|
users.users.root.openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDZm0TZPBzgXrY1vrLoYviNRb/oGZQDQk9vrppPK84sN55ZPlr9VvP+JYE7Qkx8teRuH9ulxqX40+dxKaiAXMUl4HU57KPLjwCb7SnBNIFTv6ZHGxPS8ZgUzKJr4Agph51oenNEO3RziEqAo3EwK67SGnjeIYQQKcjpfwd08+PYMOjv42zSYQ9umooj5LooOvbxoogZ3VpboXv6DeyA4rev1M9RgnMWaWVF2LxJjQ3jVr7xh1vZktVGKuVk/XXKD6WVAuwmGMVEouQzjtG9kepWd8FUYe+fgj5mtdqfeQP9CypxvOcb7jT20wO1Abpp5udS9iPDQHg+lafklIAeKG3qgxxhBDH3otXtnWcoeXUmDpBI8HU/8d/yrGaLHYRfy3HHiSGFq3lBgoxi83QIOl9ELeKWMJC0fWKBApm0NU0flgwfy2j7GRyXmlM7tVFyuj5RTAZNQfgD9g054di9WbtUs7sm/9r3/rQe2+3neE3Jskt4xvZK0xbc4dZSZGn4E2JDWjENqPBvQ2dU5lsjpUKTZWAnxVGPe//BErsDxNLIHWz8emG71r3Q2yud4KPdAR9CgeC8g1bwlCI6JDFZutKBzIlE3QQ4ryKJEioiUL89xi6G+nNB7W5ABsQN0ZtWvZl8TG4Wh00B+oBXzgRER5Y9SdAYcrwWxlGVxxQyElUNrw=="
|
||||||
|
];
|
||||||
|
|
||||||
time.timeZone = "Europe/Berlin";
|
time.timeZone = "Europe/Berlin";
|
||||||
i18n.defaultLocale = "en_IE.UTF-8";
|
i18n.defaultLocale = "en_IE.UTF-8";
|
||||||
console = {
|
console = {
|
||||||
font = "Lat2-Terminus16";
|
font = "Lat2-Terminus16";
|
||||||
keyMap = "de";
|
keyMap = "de";
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
python3
|
python3
|
||||||
killall
|
killall
|
||||||
htop
|
htop
|
||||||
mosh
|
mosh
|
||||||
git
|
git
|
||||||
git-lfs
|
git-lfs
|
||||||
tig
|
tig
|
||||||
figlet
|
figlet
|
||||||
grml-zsh-config
|
grml-zsh-config
|
||||||
tmux
|
tmux
|
||||||
neovim
|
neovim
|
||||||
xh
|
xh
|
||||||
liboping
|
liboping
|
||||||
mtr
|
mtr
|
||||||
home-manager
|
home-manager
|
||||||
];
|
];
|
||||||
|
|
||||||
# zsh
|
programs.neovim = {
|
||||||
users.defaultUserShell = pkgs.zsh;
|
enable = true;
|
||||||
programs.zsh.enable = true;
|
defaultEditor = true;
|
||||||
programs.zsh.autosuggestions.enable = true;
|
viAlias = true;
|
||||||
programs.zsh.syntaxHighlighting.enable = true;
|
vimAlias = true;
|
||||||
programs.zsh.interactiveShellInit = ''
|
};
|
||||||
source ${pkgs.grml-zsh-config}/etc/zsh/zshrc
|
|
||||||
'';
|
# zsh
|
||||||
programs.zsh.promptInit = "";
|
users.defaultUserShell = pkgs.zsh;
|
||||||
|
programs.zsh.enable = true;
|
||||||
|
programs.zsh.autosuggestions.enable = true;
|
||||||
|
programs.zsh.syntaxHighlighting.enable = true;
|
||||||
|
programs.zsh.interactiveShellInit = ''
|
||||||
|
source ${pkgs.grml-zsh-config}/etc/zsh/zshrc
|
||||||
|
'';
|
||||||
|
programs.zsh.promptInit = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,55 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
imports = [./desktop.nix];
|
||||||
|
|
||||||
|
services.pipewire = {
|
||||||
|
enable = true;
|
||||||
|
alsa.enable = true;
|
||||||
|
# alsa.support32bit = true;
|
||||||
|
pulse.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.sway = {
|
||||||
|
enable = true;
|
||||||
|
wrapperFeatures = { gtk = true; };
|
||||||
|
extraPackages = with pkgs; [
|
||||||
|
swaylock
|
||||||
|
alacritty
|
||||||
|
swayidle
|
||||||
|
swaylock-effects
|
||||||
|
mako
|
||||||
|
bemenu
|
||||||
|
# - bar
|
||||||
|
i3blocks
|
||||||
|
acpi
|
||||||
|
lm_sensors
|
||||||
|
# - tools
|
||||||
|
wl-clipboard
|
||||||
|
ponymix
|
||||||
|
brightnessctl
|
||||||
|
gammastep
|
||||||
|
grim
|
||||||
|
slurp
|
||||||
|
];
|
||||||
|
};
|
||||||
|
# done my sway:
|
||||||
|
# security.pam.services.swaylock = {};
|
||||||
|
# hardware.opengl.enable = true;
|
||||||
|
# fonts.enableDefaultFonts = true;
|
||||||
|
# programs.dconf.enable = true; # gtk theme
|
||||||
|
|
||||||
|
programs.kdeconnect = {
|
||||||
|
enable = true;
|
||||||
|
# openFirewall = true; - by enable
|
||||||
|
};
|
||||||
|
programs.browserpass.enable = true;
|
||||||
|
programs.gnupg.agent = {
|
||||||
|
enable = true;
|
||||||
|
enableSSHSupport = true;
|
||||||
|
pinentryFlavor = "gnome3";
|
||||||
|
};
|
||||||
|
|
||||||
|
# services.acpid.enable = true;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -1,30 +1,17 @@
|
||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
networking.wireless.iwd.enable = true;
|
networking.wireless.iwd.enable = true;
|
||||||
systemd.network.networks.wifi.matchConfig = { Name = "wlan0";};
|
systemd.network.networks.wifi = {
|
||||||
systemd.network.networks.wifi.DHCP = "ipv4";
|
matchConfig.Name = "wlan0";
|
||||||
|
DHCP = "ipv4";
|
||||||
|
};
|
||||||
|
|
||||||
sound.enable = true;
|
sound.enable = true;
|
||||||
services.pipewire = {
|
|
||||||
enable = true;
|
|
||||||
alsa.enable = true;
|
|
||||||
#alsa.support32bit = true;
|
|
||||||
pulse.enable = true;
|
|
||||||
};
|
|
||||||
#services.acpid.enable = true;
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
iw
|
iw
|
||||||
];
|
];
|
||||||
|
|
||||||
# allow wayland / sway
|
|
||||||
hardware.opengl.enable = true;
|
|
||||||
# gtk config
|
|
||||||
programs.dconf.enable = true;
|
|
||||||
fonts.enableDefaultFonts = true;
|
|
||||||
|
|
||||||
# smartcard
|
|
||||||
services.pcscd.enable = true;
|
|
||||||
|
|
||||||
|
# smartcard
|
||||||
|
services.pcscd.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,21 +0,0 @@
|
||||||
{pkgs, config, ... }:
|
|
||||||
{
|
|
||||||
|
|
||||||
services.postgresql = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.postgresql_14;
|
|
||||||
dataDir = "/var/lib/postgres/${config.services.postgresql.package.psqlSchema}";
|
|
||||||
# dataDir = /var/lib/postgres/data;
|
|
||||||
};
|
|
||||||
|
|
||||||
users.users.genofire = {
|
|
||||||
uid = 1021;
|
|
||||||
home = "/home/genofire";
|
|
||||||
extraGroups = ["wheel"];
|
|
||||||
isNormalUser = true;
|
|
||||||
useDefaultShell = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# wayland
|
|
||||||
security.pam.services.swaylock = {};
|
|
||||||
}
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
{pkgs, config, ... }:
|
||||||
|
{
|
||||||
|
users.groups.genofire = {
|
||||||
|
gid = 1021;
|
||||||
|
};
|
||||||
|
users.users.genofire = {
|
||||||
|
uid = 1021;
|
||||||
|
home = "/home/genofire";
|
||||||
|
group = "genofire";
|
||||||
|
extraGroups = ["wheel"];
|
||||||
|
isNormalUser = true;
|
||||||
|
useDefaultShell = true;
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDZm0TZPBzgXrY1vrLoYviNRb/oGZQDQk9vrppPK84sN55ZPlr9VvP+JYE7Qkx8teRuH9ulxqX40+dxKaiAXMUl4HU57KPLjwCb7SnBNIFTv6ZHGxPS8ZgUzKJr4Agph51oenNEO3RziEqAo3EwK67SGnjeIYQQKcjpfwd08+PYMOjv42zSYQ9umooj5LooOvbxoogZ3VpboXv6DeyA4rev1M9RgnMWaWVF2LxJjQ3jVr7xh1vZktVGKuVk/XXKD6WVAuwmGMVEouQzjtG9kepWd8FUYe+fgj5mtdqfeQP9CypxvOcb7jT20wO1Abpp5udS9iPDQHg+lafklIAeKG3qgxxhBDH3otXtnWcoeXUmDpBI8HU/8d/yrGaLHYRfy3HHiSGFq3lBgoxi83QIOl9ELeKWMJC0fWKBApm0NU0flgwfy2j7GRyXmlM7tVFyuj5RTAZNQfgD9g054di9WbtUs7sm/9r3/rQe2+3neE3Jskt4xvZK0xbc4dZSZGn4E2JDWjENqPBvQ2dU5lsjpUKTZWAnxVGPe//BErsDxNLIHWz8emG71r3Q2yud4KPdAR9CgeC8g1bwlCI6JDFZutKBzIlE3QQ4ryKJEioiUL89xi6G+nNB7W5ABsQN0ZtWvZl8TG4Wh00B+oBXzgRER5Y9SdAYcrwWxlGVxxQyElUNrw=="
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue