Skip to content

Instantly share code, notes, and snippets.

@tcurdt
Last active April 30, 2025 18:08
Show Gist options
  • Save tcurdt/cf5945626830f6927070c74be33abf02 to your computer and use it in GitHub Desktop.
Save tcurdt/cf5945626830f6927070c74be33abf02 to your computer and use it in GitHub Desktop.
#!/bin/bash
mkdir -p ~/.ssh
chmod 700 ~/.ssh
echo "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA2CLOzyXcqk4uo6hCkkQAtozJCebA/Dh4ps6Vr2GVNTC7j7nF5HuT+penp/Y9yPAuTorxunmFn7BPwZggzopEgfmUQ4gf0CysTwPQMxt9yK3ZHpxgkGoJyR0n91OdPAbukqwWZHYxGGxvHNoap59kobUrIImIa97gKxW+IVKwL9iyWXyqonRpue1mf1N1ioDtPLS1yvzf4Jo7aDND+4I/34X6436VwZItUwzvhFcuNh/gQmvKpmVjD+ED2Q/yRtGq0EzsPfrDZg1ZKV5V1cT/3w7QtYFcZB9+AQxq88jVRcIlf3K45kpmbsWVfBFN6ND+NeZK1mlp/3TV8C6dNVqU2w== [email protected]" >> ~/.ssh/authorized_keys
chmod 600 ~/.ssh/authorized_keys
echo "SSH key has been added to authorized_keys."
echo "You should now be able to log in via SSH."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment