Skip to content

Instantly share code, notes, and snippets.

@LnL7
Last active August 22, 2020 10:34
Show Gist options
  • Save LnL7/bd05394218033cff17ec20eb93a44a4a to your computer and use it in GitHub Desktop.
Save LnL7/bd05394218033cff17ec20eb93a44a4a to your computer and use it in GitHub Desktop.
module replacement example
{ config, pkgs, ... }:
let
# Import unstable channel.
# sudo nix-channel --add http://nixos.org/channels/nixos-unstable nixos-unstable
unstable = import <nixos-unstable> {};
in
{
disabledModules = [ "services/databases/postgresql.nix" ];
imports =
[ # Include service from unstable channel.
<nixos-unstable/nixos/modules/services/databases/postgresql.nix>
];
services.postgresql.enable = true;
services.postgresql.packages = unstable.postgresql;
}
@nuxeh
Copy link

nuxeh commented May 2, 2020

Thanks! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment