I gang

Jenkins calling /creating script

Here is the program from the 1st line to the start of the problem in my script. What could that last problem be?

export myip="[url removed, login to view]"

export mykey="~/.ssh/[url removed, login to view]"

export mystr="sh /home/ubuntu/[url removed, login to view]"

export mycmd="$mystr $myip"

echo "myip.......$myip" >NULL

echo "mykey......$mykey" >NULL

echo "mystr......$mystr" >NULL

echo "mycmd......$mycmd" >NULL

scp -i $mykey /vol1/[url removed, login to view] ubuntu@$myip:

# THIS COMMAND BELOW DOES NOT WORK

ssh -i $mykey ubuntu@$myip ""sudo echo "$mycmd" > ./[url removed, login to view]""

# The output expected is

sudo echo "sh /home/ubuntu/[url removed, login to view] [url removed, login to view]" > ./[url removed, login to view]

Anticipating a " or character is out of sorts or something?

Færdigheder: Linux, Shell Script, UNIX

Se mere: script creating profiles, pdns script creating, script creating roll banner actionscript, creating calling card designs photoshop, php script creating virtual subdomain, script creating iis website, script creating users file, script creating exhcange accounts, script creating website, script creating pages, php script creating songs download site, php script creating sub domein, script creating wiki zoho, php script creating job portal, creating calling card photoshop

Om arbejdsgiveren:
( 49 bedømmelser ) Lyndhurst, United States

Projekt-ID: #13340655

Tildelt til:

$30 USD på 1 dag
(7 bedømmelser)
3.9

10 freelancers are bidding on average $23 for this job

dkokmadis

Hi, Why you not ping me directly? We can agree on price and work together long term

$25 USD på 1 dag
(141 bedømmelser)
5.7
cracken

Hi Ejbest2000, I am competitive to this kind of task, can take good care of this project. In fact, I already done related to this job before. Let me know the best of your time so we can discuss further based on your r Mere

$29 USD på 1 dag
(20 bedømmelser)
4.5
$25 USD på 1 dag
(16 bedømmelser)
4.1
bhupenderbassan

The quoting is indeed wrong. Here is the solution that works for me: ssh -i $mykey ubuntu@$myip "'sudo echo \"$mycmd\" > ./[url removed, login to view]'" I was bidding, so that I can give you this answer. It's just a one-lin Mere

$25 USD på 1 dag
(3 bedømmelser)
3.0
$26 USD in 6 dage
(0 bedømmelser)
0.0
aarti9

Hello, Greetings..!! As I can see that you are looking for a technical person who can assist you perfectly in your project. Well I would like to express my interest in your job as it seems very interesting pro Mere

$30 USD på 1 dag
(0 bedømmelser)
0.0
tarundagar

Hi, I think the issue in your script is that that ========================================================== [root@localhost bin]# echo $mycmd sh /home/ubuntu/[url removed, login to view] [url removed, login to view] [root@localhost bin] Mere

$10 USD på 1 dag
(0 bedømmelser)
0.0
sanketmane

Hi, I think I can help you out here and get your issue resolved. Awaiting for your response. Thanks.

$25 USD på 1 dag
(0 bedømmelser)
0.0
kamalcastro

I can provide a fix within 3 - 6 hours.

$25 USD in 0 dage
(0 bedømmelser)
0.0
nareshreddy1310

Dear, I have been working as a Test Engineer from past three years in a reputed organistaion and working for automation (using shell and perl) of telecom projects . I hope that my expereince will help you to sor Mere

$10 USD på 1 dag
(0 bedømmelser)
0.0