Add a role for loading esims onto standalone sim cards.
This commit is contained in:
33
nix/configuration/roles/esim/default.nix
Normal file
33
nix/configuration/roles/esim/default.nix
Normal file
@@ -0,0 +1,33 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
options.me = {
|
||||
esim.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
example = true;
|
||||
description = "Whether we want to install esim.";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf (config.me.esim.enable && config.me.graphical) {
|
||||
environment.systemPackages = with pkgs; [
|
||||
easylpac
|
||||
zbar # To decode qrcodes via `zbarimg <file>`
|
||||
];
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
easylpac = (final.callPackage ./package/easylpac/package.nix { });
|
||||
})
|
||||
];
|
||||
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user