在Jenkins test
项目中我有Execute shell:
dd if=/dev/urandom of=ios_512MB bs=531628032 count=1
我已经检查并配置了Send files or execute commands over SSH after the build runs
当我运行它时,我看到:
Started by user X
Building remotely on ios in workspace /data/workspace/test
[test] $ /bin/sh -xe /var/folders/9b/s86tztx90bb9c_73gtynfzx80000gn/T/hudson8582983867531973712.sh
+ dd if=/dev/urandom of=ios_512MB bs=531628032 count=1
1+0 records in
1+0 records out
531628032 bytes transferred in 44.384345 secs (11977828 bytes/sec)
SSH: Connecting from host [jenkins2.local]
SSH: Connecting with configuration [jenkins.builds] ...
我在网络流量上看到此连接及其停止。在sftp我有:
ls -lh
-rw------- 1 10048 10047 130M Apr 16 09:56 ios_512MB
在windows / ubuntu上一切正常。如何解决?
答案 0 :(得分:0)
由Execute Shell修复:
echo "mkdir ${short}/${date}
mkdir ${short}/${date}/${RANDSTR}
put ${WORKSPACE}${location}${n}${format} ${short}/${date}/${RANDSTR}/
put ${WORKSPACE}${location}${n}.html ${short}/${date}/${RANDSTR}/" | sftp -o StrictHostKeyChecking=no -P 2222 -i ~/.ssh/id_rsa jenkins.builds@sftp.example.com