Skip to content

Commit 6ff4906

Browse files
committed
Add prerun.sh and postrun.sh for kunpeng1
The files are copied from nebbiolo1. According to https://github.com/Bioconductor/BBS/blob/master/Doc/Prepare-Ubuntu-20.04-HOWTO.md#25-add-software-builds-to-biocbuilds-crontab those should be added to crontab. But for some reason only nebbiolo1 have them. All other builder don't have these scripts Signed-off-by: Martin Tzvetanov Grigorov <[email protected]>
1 parent 9aab69c commit 6ff4906

File tree

2 files changed

+49
-0
lines changed

2 files changed

+49
-0
lines changed

3.17/bioc/kunpeng1/postrun.sh

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
#!/bin/bash
2+
3+
echo ""
4+
echo "======================================================================="
5+
this_script=$(basename "$0")
6+
echo "<<< Now starting $this_script at $(date) >>>"
7+
echo "-------------------"
8+
9+
# Adapted from : http://stackoverflow.com/a/246128/320399
10+
script_dir=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
11+
. "${script_dir}"/config.sh
12+
13+
cd "$BBS_CENTRAL_RDIR"
14+
15+
# Remove target repo (no-vignettes source packages). It's no longer
16+
# needed so we can make room before we generate the HTML report below
17+
# and before we propagate packages (this will be done later by the
18+
# updateReposPkgs-bioc.sh script that we run from the biocpush
19+
# account). Can help significantly if the machine has limited disk capacity.
20+
rm -rf src
21+
22+
# Fix perms
23+
chmod -R +r .
24+
find products-in -type d -exec chmod 755 {} \;
25+
26+
set -e # Exit immediately if a simple command exits with a non-zero status.
27+
28+
$BBS_PYTHON_CMD $BBS_HOME/BBS-make-BUILD_STATUS_DB.py
29+
30+
if [ -n "$BBS_OUTGOING_MAP" ]; then
31+
$BBS_PYTHON_CMD $BBS_HOME/BBS-make-OUTGOING.py
32+
$BBS_PYTHON_CMD $BBS_HOME/BBS-make-PROPAGATION_STATUS_DB.py
33+
fi
34+
35+
# Generate the HTML report
36+
$BBS_PYTHON_CMD $BBS_HOME/BBS-report.py simple-layout
37+
REPORT_DIRNAME=$(dirname "$BBS_REPORT_PATH")
38+
REPORT_BASENAME=$(basename "$BBS_REPORT_PATH")
39+
cd "$REPORT_DIRNAME"
40+
$BBS_TAR_CMD zcf "$REPORT_BASENAME.tgz" "$REPORT_BASENAME"
41+
mv "$REPORT_BASENAME.tgz" "$BBS_REPORT_PATH"
42+
43+
# Publish it (no more --delete here, too dangerous!)
44+
$BBS_RSYNC_CMD -ave 'ssh -o StrictHostKeyChecking=no' "$BBS_REPORT_PATH/" "$BBS_PUBLISHED_REPORT_DEST_DIR/"

3.17/bioc/kunpeng1/prerun.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/bash
2+
3+
. ./config.sh
4+
5+
$BBS_PYTHON_CMD $BBS_HOME/BBS-prerun.py

0 commit comments

Comments
 (0)