generalise the ssh key upload

Change-Id: I53a4213ce6e0a724c0b9d77b29fb89f84c185bb9