I changed my configuration to try to install Godot 4.1.1, at first it worked fine, but then after a subsequent update, Godot 4.0.3 was installed on my system.
My question is: how do I force install from unstable if my Nixpkgs target a stable release (23.05 in my case)?
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{ config, pkgs, ... }:
let
unstable = import <unstable> { config = { allowUnfree = true; }; };
# truco de https://discourse.nixos.org/t/gdm-monitor-configuration/6356/4
monitorsXmlContent = builtins.readFile /home/jorge/.config/monitors.xml;
monitorsConfig = pkgs.writeText "gdm_monitors.xml" monitorsXmlContent;
raid0 = ''
DEVICE partitions
ARRAY /dev/md0 metadata=1.2 name=woody:0 UUID=b3210ef7:588e10d0:b7ada7d6:a167b92f
'';
in {
imports = [ # Include the results of the hardware scan.
./hardware-configuration.nix
];
# Bootloader.
boot = {
plymouth = { enable = true; };
tmp = { cleanOnBoot = true; };
loader = {
systemd-boot.enable = false;
timeout = 30;
efi = {
canTouchEfiVariables = true;
efiSysMountPoint = "/boot/efi";
};
grub = {
devices = [ "nodev" ];
enable = true;
efiSupport = true;
theme = pkgs.nixos-grub2-theme;
gfxmodeEfi = "1920x1080";
extraEntries = ''
menuentry "Reboot" {
reboot
}
menuentry "Poweroff" {
halt
}
'';
};
};
supportedFilesystems = [ "ntfs" ];
# Copied from virtualisation.lxd.recommendedSysctlSettings
initrd = {
kernelModules = [ "vfio_pci" "vfio" "vfio_iommu_type1" "fuse" ];
services.swraid = {
enable = true;
mdadmConf = raid0;
};
};
kernelParams = [
"amd_iommu=on"
"iommu=pt"
"kvm_amd.npt=1"
"kvm_amd.avic=1"
"quiet"
"splash"
];
kernel.sysctl = {
"fs.inotify.max_queued_events" = 1048576;
"fs.inotify.max_user_instances" = 1048576;
"fs.inotify.max_user_watches" = 1048576;
"vm.max_map_count" = 2147483642; # use by Steam Deck
"kernel.dmesg_restrict" = 1;
"net.ipv4.neigh.default.gc_thresh3" = 8192;
"net.ipv6.neigh.default.gc_thresh3" = 8192;
"kernel.keys.maxkeys" = 2000;
};
};
systemd.tmpfiles.rules =
[ "L+ /run/gdm/.config/monitors.xml - - - - ${monitorsConfig}" ];
systemd.services.plantuml = {
description = "PlantUML server";
requires = [ "docker.service" ];
after = [ "docker.service" ];
serviceConfig = {
ExecStart =
"${pkgs.docker}/bin/docker run --rm --name plantuml -p 8686:8080 plantuml/plantuml-server:jetty";
ExecStop = "${pkgs.docker}/bin/docker stop -t 2 plantuml";
Restart = "always";
};
wantedBy = [ "default.target" ];
};
systemd.services.plantuml.enable = true;
networking.hostName = "woody"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Costa_Rica";
# Select internationalisation properties.
i18n.defaultLocale = "es_CR.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "es_CR.UTF-8";
LC_IDENTIFICATION = "es_CR.UTF-8";
LC_MEASUREMENT = "es_CR.UTF-8";
LC_MONETARY = "es_CR.UTF-8";
LC_NAME = "es_CR.UTF-8";
LC_NUMERIC = "es_CR.UTF-8";
LC_PAPER = "es_CR.UTF-8";
LC_TELEPHONE = "es_CR.UTF-8";
LC_TIME = "es_CR.UTF-8";
};
# Enable the X11 windowing system.
services.xserver.enable = true;
services.xserver.videoDrivers = [ "nvidia" ];
# Enable the GNOME Desktop Environment.
services.xserver.displayManager.gdm.enable = true;
services.xserver.desktopManager.gnome.enable = true;
# Configure keymap in X11
services.xserver = {
layout = "us";
xkbVariant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
services.printing.drivers = [ pkgs.hplip ];
services.avahi.enable = true;
services.avahi.nssmdns = true;
# for a WiFi printer
services.avahi.openFirewall = true;
# activa accesorios para Xbox one
hardware.xone.enable = true;
# activa la app de Corsair
hardware.ckb-next.enable = true;
# Steam
hardware.steam-hardware.enable = true;
programs.steam = {
enable = true;
remotePlay.openFirewall = true;
};
# Enable sound with pipewire.
sound.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
security.pam.mount.additionalSearchPaths = [ pkgs.bindfs ];
security.doas.enable = false;
security.doas.extraRules = [{
users = [ "jorge" ];
keepEnv = true;
}];
security.sudo.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
services.syncthing = {
enable = true;
user = "jorge";
dataDir = "/home/jorge/Documentos/Syncthing";
configDir = "/home/jorge/Documentos/Syncthing/.config/syncthing";
extraOptions.gui = {
user = "jorge";
password = "***************";
};
};
nixpkgs.config.permittedInsecurePackages = [ "electron-11.5.0" ];
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Ledger
hardware.ledger.enable = true;
# habilita ZSH
programs.zsh.enable = true;
# habilita kdeconnect
programs.kdeconnect.enable = true;
programs.droidcam.enable = true;
# Define a user account. Don't forget to set a password with ‘passwd’.
users.users.jorge = {
isNormalUser = true;
description = "Jorge Javier Araya Navarro";
extraGroups = [ "networkmanager" "wheel" "docker" "libvirtd" ];
shell = pkgs.zsh;
};
# allow unfree software
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
nixos-grub2-theme
# otros
bindfs
pciutils
# fuentes
noto-fonts
noto-fonts-cjk
noto-fonts-emoji
mplus-outline-fonts.githubRelease
(nerdfonts.override { fonts = [ "FiraCode" "DroidSansMono" "Iosevka" ]; })
iosevka
iosevka-comfy.comfy
iosevka-comfy.comfy-motion-duo
fira
fira-code
# linea de comandos
aspell
aspellDicts.en
aspellDicts.en-computers
aspellDicts.es
bitwarden
bitwarden-cli
bitwarden-menu
butler
ccls
clang
cmake
cmake-format
cmake-language-server
coreutils
curl
d2
dig
emacs
evince
fd
firefox
git
git-crypt
gnumake
html-tidy
hunspell
hunspellDicts.en_US
hunspellDicts.es_CR
hunspellDicts.es_ES
jq
libreoffice-fresh
nixfmt
nodePackages.prettier
nodePackages_latest.js-beautify
nodePackages_latest.stylelint
plantuml
python311Packages.grip
ripgrep
rust-analyzer
shellcheck
stow
thefuck
tree
wget
xcp
libtool
clipgrab
texlive.combined.scheme-full
texlab
lua53Packages.digestif
pandoc
doas-sudo-shim
alacritty
firefox
brave
gimp
inkscape
obsidian
remnote
signal-desktop-beta
smplayer
spotify
tdesktop
vlc
zoom-us
pdfarranger
hplip
newsflash
avidemux
audacity
libsForQt5.kdenlive
mediainfo
#davinci-resolve
deluge
xsane
obs-studio
ffmpeg-full
xournalpp
syncthingtray
nextcloud-client
# entretenimiento y juegos
itch
prismlauncher
protonup-qt
rpcs3
heroic
droidcam
linuxKernel.packages.linux_6_1.v4l2loopback
# Gnome
gnome.gnome-tweaks
gnomeExtensions.appindicator
gnomeExtensions.clipman
gnomeExtensions.gnome-bedtime
gnomeExtensions.memento-mori
gnomeExtensions.no-overview
gnomeExtensions.pop-shell
gnomeExtensions.rounded-window-corners
gnomeExtensions.time-awareness
gnomeExtensions.wallpaper-switcher
gnomeExtensions.weather
gnomeExtensions.weather-oclock
gnomeExtensions.auto-move-windows
# temas de Gnome
theme-obsidian2
iconpack-obsidian
# privacidad
protonmail-bridge
protonvpn-gui
mu
isync
# docker
# el paquete docker ya es activado como servicio más abajo
kubecolor
kubectl
kubectx
docker-compose
# virtualization
virt-manager
# dependencias para construir Python
gcc
zlib
libffi
openssl
bzip2
readline
sqlite
xz
# Android
scrcpy
# cripto
ledger-live-desktop
# otros
gparted
# game dev
unstable.godot_4
gdtoolkit
# gaming
ckb-next
];
environment.etc = { "mdadm.conf".text = raid0; };
# coloca una biblioteca en /var para mi uso personal
fileSystems."/home/jorge/biblioteca" = {
fsType = "fuse.bindfs";
device = "/var/jorge-large";
options = [
"force-user=jorge"
"force-group=users"
"create-for-user=root"
"create-for-group=root"
];
};
# List services that you want to enablyne:
# Enable the OpenSSH daemon.
services.openssh.enable = true;
virtualisation.docker = {
enable = true;
autoPrune.enable = true;
};
services.flatpak.enable = true;
virtualisation.libvirtd.enable = true;
programs.dconf.enable = true;
# Open ports in the firewall.
networking.firewall.allowedTCPPorts = [ 22 8384 22000 ];
networking.firewall.allowedUDPPorts = [ 22000 21027 ];
# networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# 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.05"; # Did you read the comment?
}