Skip to content

Commit

Permalink
Added new gitlab-ci stage for automatically creating the AppImages
Browse files Browse the repository at this point in the history
  • Loading branch information
scopplestone committed Jan 15, 2025
1 parent b2491f7 commit b8963ab
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 2 deletions.
42 changes: 41 additions & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ stages:
- reggie_weekly
- documentation
- deploy
- appimage

# ----------------------------------------------------------------------------------------------------------------------------------------------------
# Templates ("hidden jobs")
Expand Down Expand Up @@ -1086,4 +1087,43 @@ github:
- git clone -b master --single-branch [email protected]:piclas/piclas.git piclas_github ;
- cd piclas_github ;
- git remote add piclas-framework [email protected]:piclas-framework/piclas.git ;
- git push --force --follow-tags piclas-framework master ;
- git push --force --follow-tags piclas-framework master ;

# ----------------------------------------------------------------------------------------------------------------------------------------------------
# Stage "appimage": Push the CI_COMMIT_REF_NAME branch to github to invoke creating the AppImages
# ----------------------------------------------------------------------------------------------------------------------------------------------------
github_create_appimage:
stage: appimage
tags:
- withmodules-concurrent
rules:
- if: '$DO_CREATE_APPIMAGE'
script:
- if [ -z "${DO_CREATE_APPIMAGE}" ]; then exit; fi
- rm -rf piclas-testing || true ;
- if [ -z "${CI_COMMIT_REF_NAME}" ]; then echo "CI_COMMIT_REF_NAME is empty"; exit; else echo "Cloning ${CI_COMMIT_REF_NAME}"; fi
- git clone -b ${CI_COMMIT_REF_NAME} --single-branch [email protected]:piclas/piclas.git piclas-testing
- cd piclas-testing
- git remote add piclas-testing [email protected]:scopplestone/piclas-testing.git
- git push --force piclas-testing ${CI_COMMIT_REF_NAME}

# ----------------------------------------------------------------------------------------------------------------------------------------------------
# Stage "appimage": Download the AppImages from the piclas-testing repository and test them
# ----------------------------------------------------------------------------------------------------------------------------------------------------
github_test_appimage:
stage: appimage
tags:
- withmodules-concurrent
rules:
- if: '$DO_TEST_APPIMAGE'
script:
- if [ -z "${DO_TEST_APPIMAGE}" ]; then exit; fi
- export PATH="/var/lib/gitlab-runner/.local/bin:$PATH"
- module purge || true;
- module load cmake/3.26.4 gcc/13.2.0 openmpi/4.1.5/gcc/13.2.0 hdf5/1.14.0/gcc/13.2.0/openmpi/4.1.5 hopr/master/gcc/13.2.0/openmpi/4.1.5/hdf5/1.14.0 petsc/3.19.3/gcc/13.2.0/openmpi/4.1.5 || true;
- rm -rf piclas-testing || true ;
- git clone -b master --single-branch [email protected]:scopplestone/piclas-testing.git piclas-testing
- cd piclas-testing
- gh run download -n ${DO_TEST_APPIMAGE}
- module li
- ./tools/testAppImages.sh . regressioncheck
2 changes: 1 addition & 1 deletion tools/testAppImages.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash
dots='..........................................................................................................................................................'
dots='................................................................................................................................................................................'

# Set colours
if test -t 1; then # if terminal
Expand Down

0 comments on commit b8963ab

Please sign in to comment.