Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
New GH action for the CI of BigDFT
authorMartin Quinson <martin.quinson@ens-rennes.fr>
Mon, 13 Sep 2021 06:45:38 +0000 (08:45 +0200)
committerMartin Quinson <martin.quinson@ens-rennes.fr>
Mon, 13 Sep 2021 07:10:07 +0000 (09:10 +0200)
.github/workflows/ci-bigdft.yml [new file with mode: 0644]
tools/jenkins/ci-bigdft.sh [new file with mode: 0755]

diff --git a/.github/workflows/ci-bigdft.yml b/.github/workflows/ci-bigdft.yml
new file mode 100644 (file)
index 0000000..76a8bc6
--- /dev/null
@@ -0,0 +1,34 @@
+name: CI BigDFT
+
+on:
+  workflow_dispatch:
+  schedule:
+    - cron: '43 18 * * 0'
+
+jobs:
+  build:
+
+    runs-on: ubuntu-latest
+    container: simgrid/unstable
+
+    steps:
+      - uses: actions/checkout@v2
+      - name: Build and test BigDFT
+        run: |
+          set -e
+          ./tools/jenkins/ci-bigdft.sh
+
+      - name: Create the failure Message
+        if: ${{ failure() }}
+        run: |
+          echo "{\"attachments\": [{\"color\": \"#FF0000\", \"text\":\"BigDFT failed to build on simgrid/unstable docker image! See ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
+      - name: Create the success Message
+        if: ${{ success() }}
+        run: |
+          echo "{\"attachments\": [{\"color\": \"#00FF00\", \"text\":\"BigDFT successfully built on simgrid/unstable docker image. ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
+      - uses: mattermost/action-mattermost-notify@master
+        if: ${{ failure() }}
+        env:
+          MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
+          MATTERMOST_CHANNEL: ${{ secrets.MATTERMOST_CHANNEL}}
+
diff --git a/tools/jenkins/ci-bigdft.sh b/tools/jenkins/ci-bigdft.sh
new file mode 100755 (executable)
index 0000000..090d556
--- /dev/null
@@ -0,0 +1,37 @@
+#!/usr/bin/env sh
+set -ex
+export OMP_NUM_THREADS=1
+
+SUDO="" # to ease the local testing
+$SUDO apt-get -y update
+$SUDO apt-get -y install git
+$SUDO apt-get -y install build-essential
+$SUDO apt-get -y install python-is-python3
+$SUDO apt-get -y install python3-six
+$SUDO apt-get -y install jhbuild
+
+git clone --depth=1 https://gitlab.com/l_sim/bigdft-suite.git
+cd bigdft-suite
+
+WORKSPACE=`pwd`
+mkdir build && cd build
+
+../Installer.py autogen -y
+
+../Installer.py -f /builds/gfortran-simgrid.rc -y build
+
+#cubic version
+cd ../bigdft/tests/DFT/cubic/C
+smpirun -hostfile $WORKSPACE/simgrid-dev/examples/smpi/hostfile -platform $WORKSPACE/simgrid-dev/examples/platforms/small_platform.xml -np 8 $WORKSPACE/build/install/bin/bigdft -l no
+
+#Psolver checking with smpi_shared_malloc
+cd $WORKSPACE/build/psolver/tests
+make FC=smpif90 PS_Check
+smpirun -hostfile $WORKSPACE/simgrid-dev/examples/smpi/hostfile -platform $WORKSPACE/simgrid-dev/examples/platforms/small_platform.xml -np 4 ./PS_Check -n [57,48,63] -g F
+
+#linear scaling version (heavy, might swap)
+cd $WORKSPACE/bigdft/tests/DFT/linear/surface
+smpirun -hostfile $WORKSPACE/simgrid-dev/examples/smpi/hostfile -platform $WORKSPACE/simgrid-dev/examples/platforms/small_platform.xml -np 4 $WORKSPACE/build/install/bin/bigdft -n graphene -l no
+
+cd $WORKSPACE/build
+../Installer.py -f /builds/gfortran-simgrid.rc -y clean