Skip to content

nix: add Thales Luna HSM client package and NixOS module - #327

Merged
willyzha merged 1 commit into
lowRISC:mainfrom
willyzha:nixos-luna-hsm-client
Sep 17, 2026
Merged

willyzha merged 1 commit into
lowRISC:mainfrom
willyzha:nixos-luna-hsm-client

Conversation

@willyzha

Copy link
Copy Markdown
Collaborator

No description provided.

@willyzha
willyzha force-pushed the nixos-luna-hsm-client branch 7 times, most recently from 76c647c to 7915498 Compare September 17, 2026 19:27
@willyzha
willyzha marked this pull request as ready for review September 17, 2026 19:28
@willyzha
willyzha requested a review from clundin25 September 17, 2026 19:28
Comment on lines +31 to +35
# Option B: Pre-seed the Nix store (for pure flake builds without `--impure`)
# Add the tarball directly to `/nix/store` once:
# nix-store --add-fixed sha256 610-000397-020_SW_Linux_Luna_Client_V10.9.4_RevA.tar
# After this, pure flake commands work without `--impure`:
# sudo nixos-rebuild switch --flake .#provisioning-appliance-luna

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TIL; cool!

Comment thread flake.nix
Comment on lines -244 to +284
nixosConfigurations.provisioning-appliance = nixpkgs.lib.nixosSystem {
nixosConfigurations.provisioning-appliance-softhsm = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
self.nixosModules.provisioning-appliance-profile
self.nixosModules.softhsm-profile
self.nixosModules.ci-profile
./nix/hardware-configuration.nix
({ lib, ... }: {
networking.hostName = "provisioning-appliance";
system.stateVersion = "24.11";
boot.loader.systemd-boot.enable = lib.mkDefault true;
boot.loader.efi.canTouchEfiVariables = lib.mkDefault true;
fileSystems."/" = lib.mkDefault {
device = "/dev/disk/by-label/nixos";
fsType = "ext4";
};
})
];
};

nixosConfigurations.provisioning-appliance-luna = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
self.nixosModules.provisioning-appliance-profile
self.nixosModules.luna-hsm-profile
self.nixosModules.ci-profile
./nix/hardware-configuration.nix
({ lib, ... }: {
networking.hostName = "provisioning-appliance";
system.stateVersion = "24.11";
boot.loader.systemd-boot.enable = lib.mkDefault true;
boot.loader.efi.canTouchEfiVariables = lib.mkDefault true;
fileSystems."/" = lib.mkDefault {
device = "/dev/disk/by-label/nixos";

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's do a single system definition for now. I do think we will want to do this eventually, but we should get things working and have a plan for how we want to distribute the OS

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so you mean include both softhsm and the luna hsm client in one system definition?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry I should've clarified. Let's do just the Luna HSM for now.

I am working on a way to run integration tests against SoftHSM, de-coupled from the provisioning appliance

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please take a look if that's what you were looking for

@willyzha
willyzha force-pushed the nixos-luna-hsm-client branch from 7915498 to 19dfe50 Compare September 17, 2026 20:33
@willyzha
willyzha force-pushed the nixos-luna-hsm-client branch from 19dfe50 to c801ea2 Compare September 17, 2026 20:36
@willyzha
willyzha merged commit 25f2934 into lowRISC:main Sep 17, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants