Fix aria2c blocking when reading information
This commit is contained in:
parent
9ff5d1e62a
commit
1a44be289f
1 changed files with 1 additions and 1 deletions
|
|
@ -66,7 +66,7 @@ labsync_premount() {
|
|||
labsync_mount_root() {
|
||||
labsync_info "Downloading torrent file from ${labsync_torrent}"
|
||||
while ! wget -T 10 -O /tmp/torrent "${labsync_torrent}"; do sleep 1; done
|
||||
aria2c -S -T /tmp/torrent > /tmp/torrent_info
|
||||
aria2c -S /tmp/torrent > /tmp/torrent_info
|
||||
squashfs_file="$(sed -n '/idx|path\/length/,${s/\s*1|\(.*\)$/\1/p}' /tmp/torrent_info)"
|
||||
image_size_bytes="$(sed -n 's/Total Length: .*(\([0-9,]*\)).*$/\1/p' /tmp/torrent_info | tr -d ',')"
|
||||
torrent_name="$(sed -n 's/^Name: \(.*\)$/\1/p' /tmp/torrent_info)"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue