Sed -i 's/#RSAAuthentication/RSAAuthentication/g' /etc/ssh/sshd_config # modify ssh login file to allow SSH key logins Creating"Įcho "Key is already present in authorized_keys" Creating: $dir1"įile1="/home/$userid/.ssh/authorized_keys"Įcho "authorized_keys did not exist. # Ensure the user specified in $userid existsĮcho "the user specified in the script settings: $, does not exist."Įcho "You must edit this script and populate the userid variable with a valid user"Įcho ".ssh dir did not exist. # The public SSH key (you probably used puttygen to create)Įcho -e "Script last modified. # The user account you are enabling logins for You must specify the public SSH key in publicSSHKey (Use putty's puttygen to create this"). You must specify a valid user for the userid. # Adds an SSH key to the authorized_keys file and allows system to accept SSH keys for login Execute the following as root… with sudo. I called mine AddSSH.sh (chmod +x AddSSH.sh)Ħ. Copy the following into an executable file on your linux box. Save the private key to disk (copy the text of the public key and paste it into the script below for the value of publicSSHKey)ĥ. In the program files folder of putty, start the app named puttygenģ. ![]()
![]() ![]() The script I created helps propagate my public ssh key.Ģ. For a more intuitive tutorial on my first steps 1-4, refer to something like this. UPDATE: This post is primarily to share the bash script I wrote. I got really tired of this and so I decided to automate with a bash script in a secure way with ssh keys instead of passwords. #MAESTRO RADIO AUTOMATION SOFTWARE PASSWORD#The client I’m working for forces password updates every ~3 months, which means the 100 or so servers I’m logging into need to have their saved passwords updated in my SSH client software. #MAESTRO RADIO AUTOMATION SOFTWARE WINDOWS#Even to the extent of securely encrypting the user’s credentials to a Windows store so it only needed to be typed on first run. The goal was a ‘single click’ deploy app and I did everything to reach that goal. □Įvery deployment option was given a radio buton, tab, or drop down and a default value so that anyone could run the deploy process. My motivation was to simplify this disjointed release process that spanned ~30 Linux/Windows servers & took up to an hr, so that anyone could run the deploy, and thereby freeing me to enjoy MY weekends. #MAESTRO RADIO AUTOMATION SOFTWARE SOFTWARE#Steve made devices simpler by eliminating butons, software simpler by eliminating features, and interfaces simpler by eliminating options.ĭuring one point I was on-call 4 weeks in a row accountable 24/7 to ensure builds were released at the beck and call of anyone in Dev or QA departments. To be truly simple, you have to go really deep. It involves digging through the depth of the complexity. It’s not just minimalism or the absence of clutter. Simplicity is the ultimate sophistication. Let’s look at few quotes that really speak to me, of which I read in his biography: I’m a huge proponent of automation and simplification of complex processes– Even to the extent that I automate myself out of a job □ I’m also a huge fan of Steve Jobs work. I called it our Self Deploy app, and it did just that. GREAT WORK J!!! Thanks, – David Kuhl (VP, Corporate IT) So what are they talking about you may ask? This rocks-many thanks! I love automation. J Regards, – Tony Niderost (Sr. Outstanding work … Great feedback, especially for a 1.0 release! The efficiencies you have built into the process and the tool provide material improvements and time savings for the program! Looking forward to v2.0 and integration with more applications. Super work! With my utmost gratitude, – Helen Baker (CCT Director) Very impressive! – John Beaver (Software Developer) Using the deployment automation tool, I just did a hot deploy of the training system for the first time, literally 5 minutes before a meeting at which I was going to demonstrate it, and the process was almost too intuitive and painless. Have a look at what’s been said about one of my projects:
0 Comments
Leave a Reply. |
Details
AuthorAntoine ArchivesCategories |