feat: replace NM by iwd
This commit is contained in:
		
							parent
							
								
									515d8890a2
								
							
						
					
					
						commit
						16bf8c6693
					
				
					 8 changed files with 70 additions and 10 deletions
				
			
		
							
								
								
									
										3
									
								
								config
									
										
									
									
									
								
							
							
						
						
									
										3
									
								
								config
									
										
									
									
									
								
							|  | @ -24,13 +24,14 @@ pkg=( | |||
|     fzf | ||||
|     git | ||||
|     htop | ||||
|     iwd iptables-nft wireguard-tools bind gnu-netcat | ||||
|     jq | ||||
|     lf | ||||
|     linux{,-lts,-firmware} mkinitcpio | ||||
|     neofetch | ||||
|     neovim{,-lspconfig} python-pynvim ripgrep tree-sitter-cli bash-language-server pyright python-black | ||||
|     networkmanager iptables-nft wireguard-tools bind gnu-netcat | ||||
|     opendoas | ||||
|     openssh | ||||
|     p7zip unrar | ||||
|     podman{,-compose} | ||||
|     reflector | ||||
|  |  | |||
|  | @ -4,6 +4,7 @@ | |||
| pkg=( | ||||
|     aerc w3m | ||||
|     alacritty | ||||
|     bluez{,-utils} | ||||
|     dunst libnotify | ||||
|     feh | ||||
|     gammastep | ||||
|  | @ -11,9 +12,9 @@ pkg=( | |||
|     materia-gtk-theme papirus-icon-theme | ||||
|     monero | ||||
|     mpv | ||||
|     newsraft | ||||
|     #newsraft | ||||
|     noto-fonts{,-cjk,-emoji} ttf-{dejavu,liberation} otf-font-awesome | ||||
|     pass{,-otp} | ||||
|     pass{,-otp} gcr | ||||
|     pcmanfm-gtk3 | ||||
|     polkit-gnome | ||||
|     qemu-{base,audio-pipewire,hw-display-virtio-{gpu,vga},ui-gtk} dnsmasq | ||||
|  |  | |||
|  | @ -3,10 +3,6 @@ | |||
| pac "${pkg[@]}" flatpak xdg-desktop-portal-gtk mesa | ||||
| flatpak install -y "${flatpakpkg[@]}" | ||||
| 
 | ||||
| if lsusb | grep -q Bluetooth; then | ||||
|     pac bluez bluez-utils | ||||
| fi | ||||
| 
 | ||||
| case "$(lspci | grep 'VGA\|3D')" in | ||||
|     *AMD*)    pac vulkan-radeon ;; | ||||
|     *Intel*)  pac vulkan-intel ;; | ||||
|  |  | |||
|  | @ -1,2 +0,0 @@ | |||
| [main] | ||||
| dns=systemd-resolved | ||||
							
								
								
									
										24
									
								
								rootfs/etc/systemd/network/20-ethernet.network
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								rootfs/etc/systemd/network/20-ethernet.network
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,24 @@ | |||
| [Match] | ||||
| # Matching with "Type=ether" causes issues with containers because it also matches virtual Ethernet interfaces (veth*). | ||||
| # See https://bugs.archlinux.org/task/70892 | ||||
| # Instead match by globbing the network interface name. | ||||
| Name=en* | ||||
| Name=eth* | ||||
| 
 | ||||
| [Link] | ||||
| RequiredForOnline=routable | ||||
| 
 | ||||
| [Network] | ||||
| DHCP=yes | ||||
| MulticastDNS=yes | ||||
| 
 | ||||
| # systemd-networkd does not set per-interface-type default route metrics | ||||
| # https://github.com/systemd/systemd/issues/17698 | ||||
| # Explicitly set route metric, so that Ethernet is preferred over Wi-Fi and Wi-Fi is preferred over mobile broadband. | ||||
| # Use values from NetworkManager. From nm_device_get_route_metric_default in | ||||
| # https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/blob/main/src/core/devices/nm-device.c | ||||
| [DHCPv4] | ||||
| RouteMetric=100 | ||||
| 
 | ||||
| [IPv6AcceptRA] | ||||
| RouteMetric=100 | ||||
							
								
								
									
										20
									
								
								rootfs/etc/systemd/network/20-wlan.network
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								rootfs/etc/systemd/network/20-wlan.network
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,20 @@ | |||
| [Match] | ||||
| Name=wl* | ||||
| 
 | ||||
| [Link] | ||||
| RequiredForOnline=routable | ||||
| 
 | ||||
| [Network] | ||||
| DHCP=yes | ||||
| MulticastDNS=yes | ||||
| 
 | ||||
| # systemd-networkd does not set per-interface-type default route metrics | ||||
| # https://github.com/systemd/systemd/issues/17698 | ||||
| # Explicitly set route metric, so that Ethernet is preferred over Wi-Fi and Wi-Fi is preferred over mobile broadband. | ||||
| # Use values from NetworkManager. From nm_device_get_route_metric_default in | ||||
| # https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/blob/main/src/core/devices/nm-device.c | ||||
| [DHCPv4] | ||||
| RouteMetric=600 | ||||
| 
 | ||||
| [IPv6AcceptRA] | ||||
| RouteMetric=600 | ||||
							
								
								
									
										19
									
								
								rootfs/etc/systemd/network/20-wwan.network
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								rootfs/etc/systemd/network/20-wwan.network
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,19 @@ | |||
| [Match] | ||||
| Name=ww* | ||||
| 
 | ||||
| [Link] | ||||
| RequiredForOnline=routable | ||||
| 
 | ||||
| [Network] | ||||
| DHCP=yes | ||||
| 
 | ||||
| # systemd-networkd does not set per-interface-type default route metrics | ||||
| # https://github.com/systemd/systemd/issues/17698 | ||||
| # Explicitly set route metric, so that Ethernet is preferred over Wi-Fi and Wi-Fi is preferred over mobile broadband. | ||||
| # Use values from NetworkManager. From nm_device_get_route_metric_default in | ||||
| # https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/blob/main/src/core/devices/nm-device.c | ||||
| [DHCPv4] | ||||
| RouteMetric=700 | ||||
| 
 | ||||
| [IPv6AcceptRA] | ||||
| RouteMetric=700 | ||||
|  | @ -14,9 +14,10 @@ sed -i '/^HOOKS=(/s/filesystems/encrypt filesystems/' /etc/mkinitcpio.conf | |||
| 
 | ||||
| # Services | ||||
| systemctl enable \ | ||||
|     NetworkManager.service \ | ||||
|     iwd.service \ | ||||
|     nftables.service \ | ||||
|     reflector.timer \ | ||||
|     systemd-networkd.service \ | ||||
|     systemd-resolved.service \ | ||||
|     systemd-timesyncd.service \ | ||||
|     tlp.service | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue