Commit d1fca721 authored by incardon's avatar incardon

Addin jenkins pipeline for pdata

parent db0f8432
#!groovy
parallel (
"nyu" : {node ('nyu')
{
deleteDir()
checkout scm
stage ('build_nyu')
{
sh "./build.sh $WORKSPACE $NODE_NAME"
}
stage ('run_nyu')
{
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 1"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 2"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 3"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 4"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 5"
}
}
},
"sb15" : {node ('sbalzarini-mac-15')
{
deleteDir()
env.PATH = "/usr/local/bin:${env.PATH}"
checkout scm
stage ('build_sb15')
{
sh "./build.sh $WORKSPACE $NODE_NAME"
}
stage ('run_sb15')
{
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 1"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 2"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 3"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 4"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 5"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 6"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 7"
}
}
}
"gin" : {node ('gin')
{
deleteDir()
env.PATH = "/usr/local/bin:${env.PATH}"
checkout scm
stage ('build_gin')
{
sh "./build.sh $WORKSPACE $NODE_NAME"
}
stage ('run_gin')
{
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 1"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 2"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 3"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 4"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 5"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 6"
sh "cd openfpm_vcluster && ./run.sh $WORKSPACE $NODE_NAME 7"
}
}
}
)
#! /bin/bash
# Make a directory in /tmp/OpenFPM_pdata
echo "Directory: $1"
echo "Machine: $2"
mkdir src/config
git submodule init
if [ $? -ne 0 ]; then
echo -e "Configure\033[91;5;1m FAILED \033[0m"
exit 1
fi
git submodule update
if [ $? -ne 0 ]; then
echo -e "Configure\033[91;5;1m FAILED \033[0m"
exit 1
fi
mkdir openfpm_numerics/src/config
if [ "$2" == "gin" ]
then
echo "Compiling on gin\n"
source ~/.bashrc
module load gcc/4.9.2
./install -s -c "--prefix=/home/jenkins/openfpm_install"
make
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
make install
source $HOME/openfpm_vars
if [ x"$3" == x"no_test" ]; then
exit 0;
fi
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
elif [ "$2" == "wetcluster" ]
then
echo "Compiling on wetcluster"
## produce the module path
source ~/.bashrc
module load gcc/4.9.2
module load openmpi/1.8.1
module load boost/1.54.0
sh ./autogen.sh
./install -s -c "--with-boost=/sw/apps/boost/1.54.0/ CXX=mpic++"
make
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
elif [ "$2" == "taurus" ]
then
echo "Compiling on taurus"
source /etc/profile
echo "$PATH"
module load eigen/3.2.0
module load suitesparse/4.2.1-gnu-multimkl
module load boost/1.60.0
module load gcc/5.3.0
module load openmpi/1.10.2-gnu
module unload bullxmpi
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/home/incard/PARMETIS/lib:/home/incard/METIS/lib:/home/incard/HDF5/lib"
./install -i "/scratch/p_ppm/" -s -c"CXX=mpic++"
make
source $HOME/openfpm_vars
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
else
echo "Compiling general"
source ~/.bashrc
./install -s
make
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
if [ x"$3" == x"no_test" ]; then
exit 0;
fi
fi
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Info:\", \"color\": \"#00FF00\", \"text\":\"$2 completed succeffuly the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
openfpm_data @ 3a6df24b
Subproject commit ff36fbed0d2065ddab22dcba8cd47b9e02288f3a
Subproject commit 3a6df24b7a165824f8f6f8521aace31d2e51774e
openfpm_devices @ f30adc13
Subproject commit ecadd99fabe515ba06f00a5e7c656777c6bb9860
Subproject commit f30adc1393b290e31ead7aad44974a9d1f1e03fe
openfpm_io @ 0f93dd4c
Subproject commit 5cf769662d6e57a7a2fd12d1cfc835fd2793bc7b
Subproject commit 0f93dd4c0ee82fce7b246e342c5f0c1d8f0c9374
openfpm_vcluster @ 0a806d05
Subproject commit 05c42b118d23d3d1f7e7616c4054f88eed7751b8
Subproject commit 0a806d052d206a4e4cdc3b77dc536f8b36e805ff
#! /bin/bash
# Make a directory in /tmp/OpenFPM_pdata
echo "Directory: $1"
echo "Machine: $2"
if [ "$2" == "gin" ]
then
source ~/.bashrc
module load gcc/4.9.2
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
source $HOME/openfpm_vars
if [ x"$3" == x"no_test" ]; then
exit 0;
fi
mpirun -np $3 ./src/pdata
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
elif [ "$2" == "wetcluster" ]
then
echo "Compiling on wetcluster"
## produce the module path
source ~/.bashrc
module load gcc/4.9.2
module load openmpi/1.8.1
module load boost/1.54.0
source $HOME/openfpm_vars
## Run on the cluster
bsub -o output_run$3.%J -K -n 2 -R "span[hosts=$4]" "module load openmpi/1.8.1 ; module load gcc/4.9.2; module load boost/1.54.0; mpirun -np $3 ./src/pdata"
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
elif [ "$2" == "taurus" ]
then
source /etc/profile
echo "$PATH"
module load eigen/3.2.0
module load suitesparse/4.2.1-gnu-multimkl
module load boost/1.60.0
module load gcc/5.3.0
module load openmpi/1.10.2-gnu
module unload bullxmpi
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/home/incard/PARMETIS/lib:/home/incard/METIS/lib:/home/incard/HDF5/lib"
source $HOME/openfpm_vars
salloc --nodes=$4 --ntasks-per-node=$5 --time=00:15:00 --mem-per-cpu=1900 --partition=haswell bash -c "ulimit -s unlimited && mpirun -np $3 src/pdata --report_level=no"
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
else
source ~/.bashrc
if [ x"$3" == x"no_test" ]; then
exit 0;
fi
source $HOME/openfpm_vars
mpirun -np $3 ./src/pdata
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to complete the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
exit 1 ;
fi
fi
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Info:\", \"color\": \"#00FF00\", \"text\":\"$2 completed succeffuly the openfpm_pdata test \" }] }" https://hooks.slack.com/services/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
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment