summaryrefslogtreecommitdiff
path: root/meta-phosphor/classes/phosphor-deploy-ssh-keys.bbclass
AgeCommit message (Collapse)AuthorFilesLines
2021-10-23Fix phosphor-deploy-ssh-keys.bbclassJonathan Doman1-36/+37
The logic was broken due to lack of quotes around the semicolon delimiters inside subshell commands. It did not work for single keys nor multiple keys provided in SSH_KEYS. This commit adds proper quotes, and also refactors the loop a bit to reduce repeated commands, reduce indentation, and clarify variables. Tested: - Added INHERIT/SSH_KEYS to local.conf as described in script comments. - Tested with 1 key: "root:/path/to/key.pub" and 2 keys "root:/path/to/key.pub;root:/path/to/key2.pub". - Verified that in all cases keys were added to authorized_keys files exactly once by checking rootfs output: (build/tmp/work/<machine>/<image>/<version>/rootfs/home/root/.ssh/authorized_keys) Signed-off-by: Jonathan Doman <jonathan.doman@intel.com> Change-Id: I58af4e8107daa6447b8276a66fc7c91e346c7dd5
2020-11-12meta-phosphor: bbclass to deploy test SSH keysJean-Marie Verdun1-0/+62
(From meta-phosphor rev: 75c8dc6f5fc565a92da9129291ea09319e8593a6) Change-Id: I375e188abbf3115e00d3ace1ad201d9fc11214d9 Signed-off-by: Jean-Marie Verdun <jean-marie.verdun@hpe.com> Signed-off-by: Andrew Geissler <geissonator@yahoo.com>