cloud-localds option to add SSH public key

Bug #1912904 reported by Michael Vorburger
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-utils
Invalid
Wishlist
Unassigned

Bug Description

I've written a script which creates a cloud-init seed ISO using the current user's pubkey as user-data.

It's currently at https://github.com/archlinux/archiso/compare/master...vorburger:create_cloud-init.sh, and an (evolution of it) should land in Arch Linux sooner or later, watch https://gitlab.archlinux.org/archlinux/archiso/-/merge_requests/117.

But perhaps this is something that cloud-localds could natively support out of the box already?

What if one could just use it WITHOUT having to hand write a user-data file, and it would generate it, given a public key (perhaps with options to choose which one, by ID or file name; as suggested in the ongoing review discussion of the Arch MR)?

Would a PR contribution proposing to add an option for this potentially be welcome in this project?

Revision history for this message
Scott Moser (smoser) wrote :

it seems like a fine idea, implementation details aside.

things to think about:
 * it would be backwards incompatible to change the meaning of the arguments (user-data [meta-data]).
 * if you add something like --ssh-keys=, then is that incompatible with providing user-data, or do you read and edit the provided user-data to insert the keys. what if there are already keys there? append, overwrite ...

its a fine idea, you just have to work out things like that.

I'd suggest that one thing you'd want to do is allow input into ssh-import-id, so that i could have it use my github or launchpad keys magically. I think its probably best in that path to retrieve the keys "client side" rather than using cloud-init's 'ssh_import_id' support.

Revision history for this message
Paride Legovini (paride) wrote :

Hi Michael,

+1 on Scott's comment. Please note that while issues are tracked here on Launchpad cloud-utils' development happens on GitHub [1].

[1] https://github.com/canonical/cloud-utils/

Changed in cloud-utils:
status: New → Triaged
importance: Undecided → Wishlist
Revision history for this message
Paride Legovini (paride) wrote :
Changed in cloud-utils:
status: Triaged → Does Not Exist
status: Does Not Exist → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.