Skip to content

Instantly share code, notes, and snippets.

@rossedman
Last active October 29, 2018 00:29
Show Gist options
  • Save rossedman/a55c579e06c72f2f7cb5d16add8e586a to your computer and use it in GitHub Desktop.
Save rossedman/a55c579e06c72f2f7cb5d16add8e586a to your computer and use it in GitHub Desktop.
#!/bin/bash
# this pull and run script on server
# bash <(curl -L tiny.cc/rossedman-ssh)
mkdir ~/.ssh
touch ~/.ssh/authorized_keys
chmod 700 ~/.ssh && chmod 600 ~/.ssh/*
curl https://github.com/rossedman.keys >> ~/.ssh/authorized_keys
echo "rossedman ALL=(ALL) NOPASSWD: ALL" | sudo tee --append /etc/sudoers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment