.gitlab-ci.yml 1.37 KB
Newer Older
Rohit Gupta's avatar
Rohit Gupta committed
1
job1:
2 3 4 5
  script:
   - echo $PWD
   - echo $USER
   - echo $OAI_USER
Rohit Gupta's avatar
Rohit Gupta committed
6
   - echo $OAI_EXTRA_ARGS
Rohit Gupta's avatar
Rohit Gupta committed
7 8
   - echo $NFS_SHARE_DIR
   - echo $EXTERNAL_SHARE_DIR
9
   - git rev-parse --abbrev-ref HEAD
Rohit Gupta's avatar
Rohit Gupta committed
10 11
   - git_head=`git rev-parse HEAD`
   - echo $git_head
Rohit Gupta's avatar
Rohit Gupta committed
12 13 14 15 16 17
   - tmp=`git show-ref --head | grep $git_head`
   - tmp=(${tmp///// })
   - git_branch=${tmp[@]:(-1)}
   - echo $git_branch
   - source oaienv
   - echo $OPENAIR_DIR
Rohit Gupta's avatar
Rohit Gupta committed
18 19 20 21
   - NFS_TEST_RESULTS_DIR=$NFS_SHARE_DIR/$git_branch/$git_head
   - EXTERNAL_SHARE_RESULTS_DIR=$EXTERNAL_SHARE_DIR/$git_branch/$git_head
   - echo $NFS_TEST_RESULTS_DIR
   - echo $EXTERNAL_SHARE_RESULTS_DIR
22
   - python $OPENAIR_DIR/cmake_targets/autotests/run_exec_lte-softmodem_tests.py -r -5GRepoHeadVersion $git_head -n $NFS_SHARE_DIR -u $OAI_USER -p $OAI_PASS `echo $OAI_EXTRA_ARGS` >& $OPENAIR_DIR/cmake_targets/autotests/python_autotest.log
23
   - mv $OPENAIR_DIR/cmake_targets/autotests/python_autotest.log $OPENAIR_DIR/cmake_targets/autotests/log/python_autotest.log
Rohit Gupta's avatar
Rohit Gupta committed
24 25
   - sshpass -p "$OAI_PASS" rsync -az -e "ssh -o StrictHostKeyChecking=no "  --rsync-path="mkdir -p $NFS_TEST_RESULTS_DIR && rsync" $OPENAIR_DIR/cmake_targets/autotests/log $OAI_USER@localhost:$NFS_TEST_RESULTS_DIR
   - sshpass -p "$OAI_PASS" rsync -az -e "ssh -o StrictHostKeyChecking=no "  --rsync-path="mkdir -p $EXTERNAL_SHARE_DIR && rsync" $OPENAIR_DIR/cmake_targets/autotests/log $OAI_USER@localhost:$EXTERNAL_SHARE_DIR