Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

executing scripts remotely at server from pipeline

examplesbdev example March 26, 2020

Hi,

I am also facing the same issue. I am trying to execute a script which will run remotely in a server using SSH-run pipe module at /home/centos/. The execute permission is available to the script. Can you please help in this regard?

 

---
image:
name: python:3.5.1

test: &test
step:
name: Connecting to CCM to run salt commands
script:
- docker run cmd.cat/envsubst envsubst
- envsubst < /home/centos/deploy.sh > deploy-out.sh
- pipe: atlassian/ssh-run:0.2.2
variables:
SSH_USER: '${STAGE_USER}'
SERVER: '${STAGE_SERVER}'
MODE: 'script'
COMMAND: 'deploy-out.sh'

pipelines:
branches:
develop:
- <<: *test
qa-*:
- <<: *test

 

Downloaded newer image for cmd.cat/envsubst:latest

envsubst < /home/centos/deploy.sh > deploy-out.sh

<1s+ envsubst < /home/centos/deploy.sh > deploy-out.shbash: /home/centos/deploy.sh: No such file or directory

1 answer

0 votes
Asim Saleem June 28, 2020

did you found any solution?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events