Hello,
I am trying to login into my private ec2 host via bastion host and execute a shell script in the host using following pipeline.
- pipe: "atlassian/ssh-run:0.4.1"
variables:
SSH_USER: 'ec2-user'
SERVER: $SERVER
SSH_KEY: $SSH_KEY
MODE: script
COMMAND: bitbucket-pipelines.sh
EXTRA_ARGS: -o ProxyCommand='ssh -i /root/.ssh/pipelines_id ec2-user@16.210.69.43 -W %h:%p'
But I always get below error :
Bad stdio forwarding specification '%h:%p''
Output:
<span>INFO: Executing the pipe...</span>
<span>INFO: Using passed SSH_KEY</span>
<span>INFO: Executing script <a href="https://bitbucket.org/kellyx/kelly-auth/src/5c835533832a039320f10ed3bad0c5d2c83674e2/bitbucket-pipelines.sh" rel="noopener noreferrer" target="_blank">bitbucket-pipelines.sh</a> on 10.9.181.1</span>
<span>ssh -i /root/.ssh/pipelines_id -o StrictHostKeyChecking=no -p 22 -o ProxyCommand='ssh -i /root/.ssh/pipelines_id <a href="mailto:ec2-user@13.213.65.49" rel="noopener nofollow noreferrer" target="_blank">ec2-user@16.210.69.43</a> -W %h:%p' <a href="mailto:ec2-user@10.0.141.68" rel="noopener nofollow noreferrer" target="_blank">ec2-user@10.0.141.68</a> bash -s</span>
<span>Bad stdio forwarding specification '%h:%p''</span>
<span>✖ Execution failed.</span><span>Status: Downloaded newer image for bitbucketpipelines/ssh-run:0.4.1</span>
Can someone please help me with this ?