Commit e77364e0 authored by incardon's avatar incardon

Added jenkin pipelines

parent ff36fbed
#!groovy
parallel (
"nyu_VALGRIND" : {node ('nyu')
{
checkout scm
stage ('build_nyu_val')
{
sh "./build.sh $WORKSPACE $NODE_NAME VALGRIND"
}
stage ('run_nyu_val')
{
sh "cd openfpm_data && ./run.sh $WORKSPACE $NODE_NAME VALGRIND"
}
}
},
"nyu_NO" : {node ('nyu')
{
checkout scm
stage ('build_nyu_nor')
{
sh "./build.sh $WORKSPACE $NODE_NAME NO"
}
stage ('run_nyu_nor')
{
sh "cd openfpm_data && ./run.sh $WORKSPACE $NODE_NAME NO"
}
}
},
"nyu_SE" : {node ('nyu')
{
checkout scm
stage ('build_nyu_se')
{
sh "./build.sh $WORKSPACE $NODE_NAME SE"
}
stage ('run_nyu_se')
{
sh "cd openfpm_data && ./run.sh $WORKSPACE $NODE_NAME SE"
}
}
},
"sb15_VALGRIND" : {node ('sbalzarini-mac-15')
{
env.PATH = "/usr/local/bin:${env.PATH}"
checkout scm
stage ('build_sb15_val')
{
sh "echo $PATH && ./build.sh $WORKSPACE $NODE_NAME VALGRIND"
}
stage ('run_sb15_val')
{
sh "cd openfpm_data && ./run.sh $WORKSPACE $NODE_NAME VALGRIND"
}
}
},
"sb15_NO" : {node ('sbalzarini-mac-15')
{
env.PATH = "/usr/local/bin:${env.PATH}"
checkout scm
stage ('build_sb15_nor')
{
sh "./build.sh $WORKSPACE $NODE_NAME NO"
}
stage ('run_sb15_nor')
{
sh "cd openfpm_data && ./run.sh $WORKSPACE $NODE_NAME NO"
}
}
},
"sb15_SE" : {node ('sbalzarini-mac-15')
{
env.PATH = "/usr/local/bin:${env.PATH}"
checkout scm
stage ('build_sb15_se')
{
sh "./build.sh $WORKSPACE $NODE_NAME SE"
}
stage ('run_sb15_se')
{
sh "cd openfpm_data && ./run.sh $WORKSPACE $NODE_NAME SE"
}
}
}
)
#! /bin/bash
# Make a directory in /tmp/openfpm_data
echo "Build on: $2 with $3"
mkdir /tmp/openfpm_data_$3
mv * .[^.]* /tmp/openfpm_data_$3
mv /tmp/openfpm_data_$3 openfpm_data
mkdir openfpm_data/src/config
git clone git@ppmcore.mpi-cbg.de:incardon/openfpm_devices.git openfpm_devices
cd "$1/openfpm_data"
pre_command=""
sh ./autogen.sh
if [ "$2" == "master" ]; then
options="$options --disable-gpu"
fi
if [ x"$3" == x"SE" ]; then
options="$options --enable-se-class1 --enable-se-class2 --enable-se-class3 --with-action-on-error=throw --enable-test-coverage"
opt_comp="for security enhancement"
fi
if [ x"$3" == x"VALGRIND" ]; then
pre_command="valgrind --leak-check=full"
options="$options --disable-gpu --enable-test-coverage"
opt_comp="for valgrind test"
fi
sh ./configure $options
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to comfigure openfpm_data test $opt_comp \" }] }" https://hooks.slack.com/services/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
exit 1
fi
make
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed to compile the openfpm_data test $opt_comp \" }] }" https://hooks.slack.com/services/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
exit 1
fi
......@@ -19,6 +19,7 @@ m4_ifdef([AX_BOOST_PROGRAM_OPTIONS],,[m4_include([m4/ax_boost_program_options.m4
m4_ifdef([AX_BOOST_UNIT_TEST_FRAMEWORK],,[m4_include([m4/ax_boost_unit_test_framework.m4])])
m4_ifdef([AX_BOOST_TIMER],,[m4_include(m4/ax_boost_timer.m4)])
m4_ifdef([AX_BOOST_SYSTEM],,[m4_include(m4/ax_boost_system.m4)])
m4_ifdef([AX_LIB_HILBERT],,[m4_include(m4/ax_libhilbert.m4)])
case $host_os in
*cygwin*)
......
$pre_command ./src/mem_map
if [ $? -ne 0 ]; then
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Error:\", \"color\": \"#FF0000\", \"text\":\"$2 failed the test with openfpm_data test $opt_comp \" }] }" https://hooks.slack.com/services/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
exit 1
fi
curl -X POST --data "payload={\"icon_emoji\": \":jenkins:\", \"username\": \"jenkins\" , \"attachments\":[{ \"title\":\"Info:\", \"color\": \"#00FF00\", \"text\":\"$2 completed succeffuly the openfpm_data test $opt_comp \" }] }" 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