Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nixos/vault: implement RFC0042 #328002

Closed
wants to merge 1 commit into from
Closed

Conversation

aanderse
Copy link
Member

Description of changes

this PR contributes to #144575 by migrating the vault module to RFC42

i intended this change to be as minimally intrusive as possible, though one might argue i'm breaking stuff willy nilly because i removed 4 options: listenerExtraConfig, storageConfig, telemetryConfig, and extraConfig

while i feel bad about breaking things the added maintenance burden in generating a configuration file that preserves these removed options isn't worth the hassle for people who work on this module

remaining tasks:

  • gather some feedback
  • test this module on my vault instance which uses the raft storage protocol
  • write release notes

cc @jelle-bigbridge as someone who somewhat recently contributed to the module... maybe you want to test this 😄

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 24.11 Release Notes (or backporting 23.11 and 24.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@aanderse aanderse requested review from Mic92, roberth and LnL7 July 17, 2024 19:33
@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` labels Jul 17, 2024
listenerExtraConfig = mkOption {
type = types.lines;
default = ''
tls_min_version = "tls12"
Copy link
Member Author

Choose a reason for hiding this comment

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

this was removed because this is already the default value vault uses and therefore redundant

source: https://developer.hashicorp.com/vault/docs/configuration/listener/tcp#tls_min_version

@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10 labels Jul 17, 2024
@pingiun
Copy link
Member

pingiun commented Jul 18, 2024

Thank you for tagging me (@jelle-bigbridge is my old account). Unfortunately I'm unable to test this as we migrated off of vault at work. The changes do seem good to me however. I recommend merging when the module is tested properly

@Mic92
Copy link
Member

Mic92 commented Jul 19, 2024

@ofborg test vault

@Mic92
Copy link
Member

Mic92 commented Jul 19, 2024

@ofborg build vault

@aanderse
Copy link
Member Author

unfree so i don't think anything will go here... i ran all tests locally, though

@roberth
Copy link
Member

roberth commented Jul 20, 2024

unfree so i don't think anything will go here

It is distributable and source available fwiw. In my opinion, ofborg should build it.

@roberth
Copy link
Member

roberth commented Jul 20, 2024

Perhaps OpenBao support could be added; that's proper open source, and would run in ofborg without any changes.

@aanderse
Copy link
Member Author

Perhaps OpenBao support could be added

yeah, i am sure someone will package it soon enough 👍

Copy link
Member

@roberth roberth left a comment

Choose a reason for hiding this comment

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

I hope this can make the config file generation simpler and more robust, but I can't promise that.

nixos/modules/services/security/vault.nix Show resolved Hide resolved
@Mic92
Copy link
Member

Mic92 commented Jul 21, 2024

unfree so i don't think anything will go here

It is distributable and source available fwiw. In my opinion, ofborg should build it.

* [Allow unfree redistributable builds? ofborg#687](https://github.com/NixOS/ofborg/issues/687)

Does hydra build unfreeRedistributable? Maybe we need to change license to this.

@wegank wegank added the 2.status: merge conflict This PR has merge conflicts with the target branch label Dec 10, 2024
@aanderse
Copy link
Member Author

given the work @roberth and @MattSturgeon have done on a record type i no longer feel great about moving forward with this PR, despite how the module has some serious shortcomings

if you ever feel inclined to continue the great work you were doing please ping me @MattSturgeon, as the vault module would greatly benefit from it (as would many other modules!) 🙇‍♂️

@aanderse aanderse closed this Dec 12, 2024
@aanderse aanderse deleted the nixos/vault branch December 12, 2024 20:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.status: merge conflict This PR has merge conflicts with the target branch 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants