.gitlab-ci.yml 558 Bytes
Newer Older
Muddsair Sharif's avatar
Muddsair Sharif committed
1
2
3
image: ubuntu

before_script:
Sintal's avatar
Sintal committed
4
5
6
  - echo "Hello, $GITLAB_USER_LOGIN!"
  - 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
  - eval $(ssh-agent -s)
Sintal's avatar
Sintal committed
7
8
9
  - sudo apt-get install sshpass
  - echo $SSH_PASSPHRASE
  - sshpass -p $SSH_PASSPHRASE
Sintal's avatar
Sintal committed
10
11
12
13
14
15
  - echo "$SSH_PRIVATE_KEY" | base64 -d | tr -d '\r' | ssh-add - > /dev/null
  - mkdir -p ~/.ssh
  - chmod 700 ~/.ssh
  - ssh-keyscan bwunicluster.scc.kit.edu > ~/.ssh/known_hosts
  - chmod 644 ~/.ssh/known_hosts
  - ssh $USER_NAME "pwd"
Sintal's avatar
Sintal committed
16

Muddsair Sharif's avatar
Muddsair Sharif committed
17
18
19

Test SSH:
    script:
Sintal's avatar
Sintal committed
20
      - echo "test from fork"