-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #556 from GEOS-ESM/develop
Sync develop into main
- Loading branch information
Showing
2 changed files
with
13 additions
and
148 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,7 @@ | ||
version: 2.1 | ||
|
||
executors: | ||
gfortran: | ||
docker: | ||
- image: gmao/ubuntu20-geos-env-mkl:v6.2.8-openmpi_4.0.6-gcc_11.2.0 | ||
auth: | ||
username: $DOCKERHUB_USER | ||
password: $DOCKERHUB_AUTH_TOKEN | ||
environment: | ||
OMPI_ALLOW_RUN_AS_ROOT: 1 | ||
OMPI_ALLOW_RUN_AS_ROOT_CONFIRM: 1 | ||
OMPI_MCA_btl_vader_single_copy_mechanism: none | ||
MPIEXEC_PREFLAGS: --oversubscribe | ||
resource_class: large | ||
#MEDIUM# resource_class: medium | ||
|
||
ifort: | ||
docker: | ||
- image: gmao/ubuntu20-geos-env:v6.2.8-intelmpi_2021.2.0-intel_2021.2.0 | ||
auth: | ||
username: $DOCKERHUB_USER | ||
password: $DOCKERHUB_AUTH_TOKEN | ||
resource_class: large | ||
#MEDIUM# resource_class: medium | ||
orbs: | ||
circleci-tools: geos-esm/[email protected] | ||
|
||
workflows: | ||
build-test: | ||
|
@@ -35,136 +14,22 @@ workflows: | |
context: | ||
- docker-hub-creds | ||
|
||
commands: | ||
versions: | ||
description: "Versions, etc." | ||
parameters: | ||
compiler: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Versions, etc." | ||
command: mpirun --version && << parameters.compiler >> --version && echo $BASEDIR && pwd && ls && echo "$(nproc)" | ||
|
||
compress_artifacts: | ||
description: "Compress artifacts" | ||
steps: | ||
- run: | ||
name: "Compress artifacts" | ||
command: | | ||
gzip -9 /logfiles/* | ||
checkout_fixture: | ||
description: "Checkout fixture" | ||
parameters: | ||
repo: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Checkout fixture" | ||
command: | | ||
cd ${CIRCLE_WORKING_DIRECTORY} | ||
git clone https://github.com/GEOS-ESM/<< parameters.repo >>.git | ||
mepoclone: | ||
description: "Mepo clone external repos" | ||
parameters: | ||
repo: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Mepo clone external repos" | ||
command: | | ||
cd ${CIRCLE_WORKING_DIRECTORY}/<< parameters.repo >> | ||
mepo clone | ||
mepo status | ||
mepodevelop: | ||
description: "Mepo develop GEOSgcm_GridComp GEOSgcm_App GMAO_Shared" | ||
parameters: | ||
repo: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Mepo develop GEOSgcm_GridComp GEOSgcm_App GMAO_Shared" | ||
command: | | ||
cd ${CIRCLE_WORKING_DIRECTORY}/<< parameters.repo >> | ||
mepo develop GEOSgcm_GridComp GEOSgcm_App GMAO_Shared | ||
mepo status | ||
checkout_feature_branch: | ||
description: "Mepo checkout-if-exists feature branch" | ||
parameters: | ||
repo: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Mepo checkout-if-exists feature branch" | ||
command: | | ||
cd ${CIRCLE_WORKING_DIRECTORY}/<< parameters.repo >> | ||
echo "${CIRCLE_BRANCH}" | ||
if [ "${CIRCLE_BRANCH}" != "develop" ] && [ "${CIRCLE_BRANCH}" != "main" ] | ||
then | ||
mepo checkout-if-exists ${CIRCLE_BRANCH} | ||
fi | ||
mepo status | ||
cmake: | ||
description: "Run CMake" | ||
parameters: | ||
repo: | ||
type: string | ||
compiler: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Build and install" | ||
command: | | ||
mkdir -p /logfiles | ||
cd ${CIRCLE_WORKING_DIRECTORY}/<< parameters.repo >> | ||
mkdir -p ${CIRCLE_WORKING_DIRECTORY}/workspace/build-<< parameters.repo >> | ||
cd ${CIRCLE_WORKING_DIRECTORY}/workspace/build-<< parameters.repo >> | ||
cmake ${CIRCLE_WORKING_DIRECTORY}/<< parameters.repo >> -DBASEDIR=$BASEDIR/Linux -DCMAKE_Fortran_COMPILER=<< parameters.compiler >> -DCMAKE_BUILD_TYPE=Debug -DUSE_F2PY=OFF -DMPIEXEC_PREFLAGS=${MPIEXEC_PREFLAGS} -DCMAKE_INSTALL_PREFIX=${CIRCLE_WORKING_DIRECTORY}/workspace/install-<< parameters.repo >> |& tee /logfiles/cmake.log | ||
buildinstall: | ||
description: "Build and install" | ||
parameters: | ||
repo: | ||
type: string | ||
steps: | ||
- run: | ||
name: "Build and install" | ||
command: | | ||
cd ${CIRCLE_WORKING_DIRECTORY}/workspace/build-<< parameters.repo >> | ||
make -j"$(nproc)" install |& tee /logfiles/make.log | ||
#MEDIUM# make -j4 install |& tee /logfiles/make.log | ||
jobs: | ||
build-GEOSgcm: | ||
parameters: | ||
compiler: | ||
type: string | ||
executor: << parameters.compiler >> | ||
executor: circleci-tools/<< parameters.compiler >> | ||
working_directory: /root/project | ||
steps: | ||
- run: | ||
name: "GEOSgcm_GridComp branch" | ||
command: echo ${CIRCLE_BRANCH} | ||
- checkout_fixture: | ||
repo: GEOSgcm | ||
- versions: | ||
- circleci-tools/checkout_fixture | ||
- circleci-tools/mepoclone | ||
- circleci-tools/mepodevelop | ||
- circleci-tools/checkout_if_exists | ||
- circleci-tools/cmake: | ||
compiler: << parameters.compiler >> | ||
- mepoclone: | ||
repo: GEOSgcm | ||
- mepodevelop: | ||
repo: GEOSgcm | ||
- checkout_feature_branch: | ||
repo: GEOSgcm | ||
- cmake: | ||
repo: GEOSgcm | ||
compiler: << parameters.compiler >> | ||
- buildinstall: | ||
repo: GEOSgcm | ||
- compress_artifacts | ||
- circleci-tools/buildinstall | ||
- circleci-tools/compress_artifacts | ||
- store_artifacts: | ||
path: /logfiles | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters