Find Jobs
Hire Freelancers

bash create user

$10-30 USD

Imefungwa
Imechapishwa almost 2 years ago

$10-30 USD

Kulipwa wakati wa kufikishwa
Hello - please see my script below - need this to create a user on the remote host (ubuntu raspberry pi) - this should be a key enabled user, the name is myansible as you can see...- the script should be able to run the last 3 lines successfully after the above script with your input (OPEN TO YOUR SUGGESTIONS AND CORRECTIONS) #!/bin/bash if [ -z $1 ] || [ -z $2 ] || [ -z $3 ] then echo " " echo 'SYNTAX ./[login to view URL] <ip> <username> <password>' echo "this is to create keys and make passwords unusable" exit 100 fi echo "ipaddresss...........$1" echo "username.............$2" echo "password.............$3" # set -x ssh-keygen -q -t rsa -N '' -f ~/.ssh/tmp-pi-key <<<y >/dev/null 2>&1 sshpass -p x ssh-copy-id -i ~/.ssh/[login to view URL] pi@[login to view URL] ls -la ~/.ssh | grep tmp #scp -i ~/.ssh/tmp-pi-key [login to view URL] $2@$1:~ ssh $2@$1 "sudo ls -l /home" ssh $2@$1 "sudo userdel myansible && sudo rm -Rf /home/myansible/" ssh $2@$1 "sudo -S useradd myansible -m -s /bin/bash" ssh $2@$1 "sudo cat /etc/passwd | grep myansible" ssh $2@$1 "sudo mkdir -vp /home/myansible/.ssh" ssh $2@$1 "sudo ls -l /home/myansible" ssh $2@$1 "sudo ls -l /home/myansible/.ssh" ssh $2@$1 "sudo chown -R myansible:myansible /home/myansible" ssh -i ~/.ssh/tmp-pi-key myansible@$1 "pwd" ssh -i ~/.ssh/tmp-pi-key myansible@$1 "ls -latr" ssh -i ~/.ssh/tmp-pi-key myansible@$1 "pwd" There is hope you can give your “best” price; unemployed, and have cancer with bills backing up, $12 possible? Glowing paragraph of feedback 5 stars My funds are low but will pay quick and leave 5 stars. Please give your best possible for your bid ? (something reasonable?) Please note there is hope we can mutually complete this task; we can leave each other nice comments and 5 stars for each? Look at feedback on my profile, feedback I left for many others. Here is the project: SINCERELY WOULD BE NICE TO MEET YOU PLEASE ANY THOUGHTS ? Please note project is due in two hours as this projects deadline, as this is needed if we can get some done - then we can talk about next steps and 5 stars and another job also. If this is a good one and we are "successful"; would need a couple others setup, but will handle one at a time? Can you do this for something reasonable in a couple hours? thoughts ?
Kitambulisho cha mradi: 33889119

Kuhusu mradi

4 mapendekezo
Mradi wa mbali
Inatumika 2 yrs ago

Unatafuta kupata pesa?

Faida za kutoa zabuni kwenye Freelancer

Weka bajeti yako na muda uliopangwa
Pata malipo kwa kazi yako
Eleza pendekezo lako
Ni bure kujiandikisha na kutoa zabuni kwa kazi
4 wafanyakazi huru wana zabuni kwa wastani $20 USD kwa kazi hii
Picha ya Mtumiaji
Hi, do you want to create a user named myansible and change the password of myansible? If so, here is a simple script function that I can do in a day.
$10 USD ndani ya siku 1
0.0 (0 hakiki)
0.0
0.0

Kuhusu mteja

Bedera ya UNITED STATES
Lyndhurst, United States
5.0
493
Njia ya malipo imethibitishwa
Mwanachama tangu Sep 14, 2013

Uthibitishaji wa Mteja

Asante! Tumekutumia kiungo cha kudai mkopo wako bila malipo kwa barua pepe.
Hitilafu fulani imetokea wakati wa kutuma barua pepe yako. Tafadhali jaribu tena.
Watumiaji Waliosajiliwa Jumla ya Kazi Zilizochapishwa
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Onyesho la kukagua linapakia
Ruhusa imetolewa kwa Uwekaji wa Kijiografia.
Muda wako wa kuingia umeisha na umetoka nje. Tafadhali ingia tena.