Skip to content

Commit 084cf33

Browse files
cleanups, first attempt at pages upload
1 parent 1eb8e7f commit 084cf33

File tree

3 files changed

+85
-23
lines changed

3 files changed

+85
-23
lines changed

.github/workflows/autobuild.yml

+55-11
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@ on:
66
- cron: '15 06 * * *' # UTC 6:15am, corresponds to 00:15 CST or 01:15 CDT
77
push:
88
paths:
9-
# Also run the build when this file gets modified as part of a PR
9+
# Also run the build when these files are modified as part of a PR
1010
- '.github/workflows/autobuild.yml'
1111
- '.github/workflows/delta-sbatch-slurm.sh'
12+
- '.github/workflows/jobmonitor.sh'
1213

1314

1415
# Cancel in progress CI runs when a new run targeting the same PR or branch/tag is triggered.
@@ -18,14 +19,20 @@ concurrency:
1819
cancel-in-progress: true
1920

2021
jobs:
21-
Delta:
22+
delta:
2223
timeout-minutes: 60
2324

24-
runs-on: delta
25+
permissions:
26+
# Give the default GITHUB_TOKEN write permission to commit and push the
27+
# added or changed files to the repository.
28+
contents: write
29+
30+
# runs-on: delta
31+
runs-on: ubuntu-latest
2532
name: Delta mpi-linux-x86_64 # Could test various builds (e.g., MPI, UCX, ...) via a build matrix
2633

2734
steps:
28-
- uses: actions/checkout@v3
35+
- uses: actions/checkout@v4
2936
- name: Host info
3037
run: |
3138
set -x
@@ -36,15 +43,52 @@ jobs:
3643
pwd
3744
- name: build
3845
run: |
39-
set -ex
40-
export target="mpi-linux-x86_64"
41-
.github/workflows/jobmonitor.sh .github/workflows/delta-sbatch-slurm.sh
46+
set -x
47+
# export target="mpi-linux-x86_64"
48+
# .github/workflows/jobmonitor.sh .github/workflows/delta-sbatch-slurm.sh
49+
50+
echo 0 > result.latest
51+
echo "hello world" > output.latest
52+
53+
- name: Check out autobuild-logs repo
54+
uses: actions/checkout@v4
55+
with:
56+
repository: UIUC-PPL/autobuild-logs
57+
token: ${{ secrets.GITHUB_TOKEN }}
58+
path: autobuild-logs
59+
4260
- name: results
4361
run: |
62+
set -x
63+
cat result.latest
4464
if grep '0' result.latest
4565
then
46-
echo "Success"
66+
res="success"
4767
else
48-
echo "Failure"
49-
fi
50-
# should also https://github.com/marketplace/actions/send-email
68+
res="failure"
69+
fi
70+
71+
pwd
72+
echo $res
73+
74+
cd autobuild-logs
75+
mkdir -p delta/mpi-linux-x86_64
76+
cd delta/mpi-linux-x86_64
77+
78+
cp ../../../output.latest Delta_mpi-linux-x86_64_$(date '+%Y-%m-%dT%H-%M-%S%z')_output_$res.txt
79+
80+
- uses: stefanzweifel/git-auto-commit-action@v5
81+
with:
82+
commit_message: Autobuild results for delta/mpi-linux-x86_64
83+
repository: autobuild-logs
84+
85+
# git config --global user.email "autobuild-logs@charm"
86+
# git config --global user.name "Autobuild-logs user"
87+
88+
# git add .
89+
90+
# git commit -m "Autobuild results for delta/mpi-linux-x86_64"
91+
92+
# git push
93+
94+
# # should also https://github.com/marketplace/actions/send-email

.github/workflows/delta-sbatch-slurm.sh

+15-6
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,24 @@
77
#SBATCH -J autobuild
88
#SBATCH -p cpu
99
#SBATCH -A mzu-delta-cpu
10-
#cd $indir
10+
1111
set -x
12+
1213
module load libfabric; module load cmake
13-
./build all-test $target --with-production --enable-error-checking -j64 -g
14-
#
14+
15+
mkdir -p $target
16+
17+
# ./build all-test $target --with-production --enable-error-checking -j64 -g
18+
1519
cd $target
16-
make -C tests test OPTS="$flags" TESTOPTS="$testopts" $maketestopts
17-
make -C examples test OPTS="$flags" TESTOPTS="$testopts" $maketestopts
18-
make -C benchmarks test OPTS="$flags" TESTOPTS="$testopts" $maketestopts
20+
# make -C tests test OPTS="$flags" TESTOPTS="$testopts" $maketestopts
21+
# make -C examples test OPTS="$flags" TESTOPTS="$testopts" $maketestopts
22+
# make -C benchmarks test OPTS="$flags" TESTOPTS="$testopts" $maketestopts
23+
24+
# For debugging:
25+
echo "Just 4 debugging"
26+
true
27+
1928
# Save make exit status
2029
status=$?
2130
echo $status > ../$SLURM_JOBID.result

.github/workflows/jobmonitor.sh

+15-6
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,11 @@ End() {
1010
$queue_kill $jobid
1111
exit $1
1212
}
13+
1314
echo "Submitting batch job for> $target OPTS=$flags"
1415
echo " using the command> $queue_qsub $script"
1516
chmod 755 $script
17+
1618
while [ -z "$jobid" ]
1719
do
1820
$queue_qsub $script > .status.$$ 2>&1
@@ -25,12 +27,16 @@ do
2527
jobid=`cat .status.$$ | tail -1 | awk '{print $4}'`
2628
rm -f .status.$$
2729
done
30+
2831
echo "Job enqueued under job ID $jobid"
32+
2933
export output=$jobid.output
3034
export result=$jobid.result
35+
3136
# kill job if interrupted
3237
trap 'End 1' 2 3
3338
retry=0
39+
3440
# Wait for the job to complete, by checking its status
3541
while [ true ]
3642
do
@@ -40,9 +46,9 @@ do
4046
#if [[ $exitstatus != 0 || $linecount != 2 ]]
4147
if [[ $linecount != 2 ]]
4248
then
43-
# The job is done-- print its output
49+
# The job is done-- print its output
4450
rm tmp.$$
45-
# When job hangs, result file does not exist
51+
# When job hangs, result file does not exist
4652
test -f $result && status=`cat $result` || status=1
4753
echo "==================================== OUTPUT (STDOUT & STDERR) ========================================"
4854
cat $output
@@ -57,12 +63,15 @@ do
5763
cat $result
5864
echo "======================================================================================================"
5965
fi
60-
# mv result and output to result.latest
61-
mv $result result.latest
62-
mv $output output.latest
66+
67+
# mv result and output to result.latest
68+
mv $result result.latest
69+
mv $output output.latest
70+
6371
exit $status
6472
fi
65-
# The job is still queued or running-- print status and wait
73+
74+
# The job is still queued or running-- print status and wait
6675
tail -1 tmp.$$
6776
rm tmp.$$
6877
sleep 60

0 commit comments

Comments
 (0)