s390x: Support multiple hostkeys in rdcore zipl - #1754
Conversation
Allow specifying --hostkey/-k multiple times for flexible Secure Execution configurations.
There was a problem hiding this comment.
Code Review
This pull request updates the rdcore zipl command to support multiple hostkeys via the --hostkey or -k option, transitioning the internal representation from a single string to a vector of strings. Feedback was provided to address an edge case in src/s390x/zipl.rs where an empty hostkeys vector wrapped in Some would bypass the default /etc/se-hostkeys fallback and cause an execution failure; using a match guard was suggested to resolve this.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
dustymabe
left a comment
There was a problem hiding this comment.
LGTM - one strong-ish recommendation
| /// Path to hostkey | ||
| #[arg(long, value_name = "HOSTKEY")] | ||
| pub hostkey: Option<String>, | ||
| #[arg(short = 'k', long = "hostkey", value_name = "HOSTKEY")] |
There was a problem hiding this comment.
I like long options. I won't require us to not add -k support here, but I'd recommend against it. Usually for short options (unless you use a CLI tool often by hand) you just end up looking up what it means anyway. I'd rather just keep the long option.
There was a problem hiding this comment.
Yep, long options are better. I was testing the case where many keys are required, and after typing --hostkey for the third time I ended up using the short version.
Also, pvimg-create also uses -k for a similar option:
-k, --host-key-document <FILE>
Use FILE as a host-key document. Can be specified multiple times and must be specified at least once.
Allow specifying --hostkey/-k multiple times for flexible Secure Execution configurations.