mirror of
https://github.com/donovanglover/nix-config.git
synced 2024-11-23 00:34:24 +01:00
phone: Add initial configuration
This is an initial configuration of the PinePhone with a nixpkgs build from 2023-11-15. Notably the installer uses uuids by default, so it's up to the user to specify their own hardware-configuration.nix.
This commit is contained in:
parent
fc69d7980f
commit
494f40e691
64
phone/configuration.nix
Normal file
64
phone/configuration.nix
Normal file
@ -0,0 +1,64 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
(import <mobile-nixos/lib/configuration.nix> { device = "pine64-pinephone"; })
|
||||
./hardware-configuration.nix
|
||||
<mobile-nixos/examples/phosh/phosh.nix>
|
||||
];
|
||||
|
||||
networking.hostName = "mobile-nixos";
|
||||
|
||||
#
|
||||
# Opinionated defaults
|
||||
#
|
||||
|
||||
# Use Network Manager
|
||||
networking.wireless.enable = false;
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Use PulseAudio
|
||||
hardware.pulseaudio.enable = true;
|
||||
|
||||
# Enable Bluetooth
|
||||
hardware.bluetooth.enable = true;
|
||||
|
||||
# Bluetooth audio
|
||||
hardware.pulseaudio.package = pkgs.pulseaudioFull;
|
||||
|
||||
# Enable power management options
|
||||
powerManagement.enable = true;
|
||||
|
||||
# It's recommended to keep enabled on these constrained devices
|
||||
zramSwap.enable = true;
|
||||
|
||||
# Auto-login for phosh
|
||||
services.xserver.desktopManager.phosh = {
|
||||
user = "user";
|
||||
};
|
||||
|
||||
#
|
||||
# User configuration
|
||||
#
|
||||
|
||||
users.users."user" = {
|
||||
isNormalUser = true;
|
||||
description = "User";
|
||||
password = "user";
|
||||
extraGroups = [
|
||||
"dialout"
|
||||
"feedbackd"
|
||||
"networkmanager"
|
||||
"video"
|
||||
"wheel"
|
||||
];
|
||||
};
|
||||
|
||||
# This value determines the NixOS release from which the default
|
||||
# settings for stateful data, like file locations and database versions
|
||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||
# this value at the release version of the first install of this system.
|
||||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
system.stateVersion = "23.11"; # Did you read the comment?
|
||||
}
|
19
phone/hardware-configuration.nix
Normal file
19
phone/hardware-configuration.nix
Normal file
@ -0,0 +1,19 @@
|
||||
# NOTE: this file was generated by the Mobile NixOS installer.
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
fileSystems = {
|
||||
"/" = {
|
||||
device = "/dev/disk/by-uuid/63546625-e99c-4aa4-ba11-ff193ad13047";
|
||||
fsType = "ext4";
|
||||
};
|
||||
};
|
||||
|
||||
boot.initrd.luks.devices = {
|
||||
"LUKS-MOBILE-NIXOS-ROOTFS" = {
|
||||
device = "/dev/disk/by-uuid/28e0bd73-e4fb-4002-9b17-a494823e6999";
|
||||
};
|
||||
};
|
||||
|
||||
nix.settings.max-jobs = lib.mkDefault 2;
|
||||
}
|
Loading…
Reference in New Issue
Block a user