GitLab CI: No such file or directory: 'GIT_SSH_COMMAND=ssh -vvv'

1.1k views Asked by At

I want to run git with the verbose attribute. So I want to set the variable GIT_SSH_COMMAND.

 GIT_SSH_COMMAND="ssh -vvv"
 git clone .....

But I get this error message:

 No such file or directory: 'GIT_SSH_COMMAND=ssh -vvv'

How could I solve this. It tried to define the varibale before at the .gitlab-ci.yml-file:

variables:
  GIT_SSH_COMMAND: ssh -v

before_script:
  - export GIT_SSH_COMMAND="ssh -vvv"

But this doesn't help.

1

There are 1 answers

0
VonC On

I see that variable used directly in the script step of a gitlab-ci.yml

  script:
    - pwd
    - rm -rf mace-models
    - rm -rf generic-mobile-devices
    - GIT_SSH_COMMAND="ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no" git clone [email protected]:XiaoMi/mace-models.git