Chronicling my journey and discoveries in cutting-edge software development. Here, I share practical knowledge and solutions, focusing on Ruby on Rails, Node.js, and JavaScript, alongside explorations into Kubernetes, distributed systems, and latest web technologies.
Thanks for sharing. If you are looking Ruby on Rails in India then Cryptex Solutions is the one of the most reputed company in India. We customize canavas LMS, Integrate bitcoin payment gateway and many more. For more details contact us at: info@cryptextechnologies.com
I got this error while installing Rest client perl module $ HOME=/tmp /home/perl/5.10/bin/cpanm REST::Client ! Finding REST::Client on cpanmetadb failed. ! cannot open file '/tmp/.cpanm/sources/http%www.cpan.org/02packages.details.txt.gz': No such file or directory opening compressed index ! Couldn't find module or a distribution REST::Client Solution: The problem is because of "LWP::Protocol::https" module. Removing the directory worked for me. $ cd /perl_installed_path/perl/5.10/lib/site_perl/5.10.1 $ rm –rf LWP* or try with option "--no-lwp" cpanm REST::Client --no-lwp
This is a simple script that can ssh into a server by typing the password for you. Filename: login #!/usr/bin/expect eval spawn ssh username@servername expect "assword:" send "server_password\r" interact # to run the script # ./login In this below script you can pass arguments to the shell script Filename: login #!/usr/bin/expect set num [lindex $argv 0]; eval spawn ssh username@servername-$num expect "assword:" send "server_password\r" interact # make sure to give executable permission to script. chmod +x login # to run the script and login to server-01. ./login 01 Now add the script path to your .bashrc file as alias, so that you can access this script from any path. # vi ~/.bashrc alias login='/path/to/script/file/login' After updating the .bashrc file, you will have to source. source ~/.bashrc Now call the script from anywhere in your shell. login 01 Enjoy!!!
Comments