Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions script/cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,8 @@ def rsync_commands(checksum):
break
fi
done
if [[ $src =~ .iso$ ]]; then
echo "rsync --timeout=3600 -tlp4 --specials PRODUCTISOPATH/$folder/$src /var/lib/openqa/factory/iso/"
else
echo "rsync --timeout=3600 -tlp4 --specials PRODUCTISOPATH/$folder/$src /var/lib/openqa/factory/hdd/"
fi
[[ $src =~ .iso$ ]] && asset="iso" || asset="hdd"
echo "rsync --timeout=3600 -tlp4 --specials PRODUCTISOPATH/$folder/$src /var/lib/openqa/factory/$asset/"
echo "rsync --timeout=3600 -tlp4 --specials PRODUCTISOPATH/$folder/$src.sha256 /var/lib/openqa/factory/other/"
echo ""
done < <(grep ${arch} __envsub/files_iso.lst | sort)
Expand Down Expand Up @@ -183,11 +180,12 @@ def openqa_call_start_fix_iso(archs):
return ''

def openqa_call_news(news, news_archs):
if news and news_archs:
return '''[[ ! "$flavor" =~ ''' + news + ''' ]] || [ "$arch" != ''' + news_archs + ''' ] || news["$flavor"]="$destiso"'''
if news:
return '''[[ ! "$flavor" =~ ''' + news + ''' ]] || news["$flavor"]="$destiso"'''
return ''
if not news:
return ''
news_str = '''[[ ! "$flavor" =~ ''' + news + ''' ]]'''
if news_archs:
news_str += ''' || [ "$arch" != ''' + news_archs + ''' ]'''
return news_str + ''' || news["$flavor"]="$destiso"'''

def openqa_call_start_distri(flavor_distri):
if flavor_distri:
Expand Down Expand Up @@ -257,7 +255,7 @@ def openqa_call_start_iso(checksum):
def openqa_call_start_ex1(checksum, tag):
res = tag + '=${destiso} \\\\'
if checksum:
res = res + '''
res += '''
CHECKSUM_''' + tag + '''=\$(cut -b-64 /var/lib/openqa/factory/other/${destiso}.sha256 | grep -E '[0-9a-f]{5,40}' | head -n1) \\\\
ASSET_256=${destiso}.sha256 \\\\'''
return res
Expand Down