This repository has been archived by the owner on Apr 9, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathJenkinsfile
74 lines (73 loc) · 2.65 KB
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
pipeline {
agent any
tools {
maven 'Maven 3.3.9'
jdk 'OpenJDK 8'
}
stages {
stage ('Initialize') {
steps {
sh '''
echo "PATH = ${PATH}"
echo "M2_HOME = ${M2_HOME}"
'''
}
}
stage('Build Processor') {
steps {
sh 'mvn -f "./com.viatra.cps.benchmark.reports.processing/pom.xml" install'
}
}
stage('Update viatra-cps-benchmark-results') {
steps {
sshagent(['24f0908d-7662-4e93-80cc-1143b7f92ff1']) {
sh "./clone-results.sh"
}
}
}
stage('Process'){
steps{
sshagent(['24f0908d-7662-4e93-80cc-1143b7f92ff1']) {
sh './com.viatra.cps.benchmark.reports.processing/run.sh "m2m-reduced" "./viatra-cps-benchmark-results" "./com.viatra.cps.benchmark.reports.processing/config.json" "./out" "./com.viatra.cps.benchmark.reports.processing/diagramConfigTemplate.json" "./out" "./com.viatra.cps.benchmark.reports.processing" < ./com.viatra.cps.benchmark.reports.processing/builds.txt'
}
}
}
stage('Initialize visualizer'){
steps{
nodejs(nodeJSInstallationName: 'Latest'){
sh '''
cd ./resultVisualizer
npm install
'''
}
}
}
stage('Build visualizer'){
steps{
nodejs(nodeJSInstallationName: 'Latest'){
sh '''
rm -rf ./resultVisualizer/src/results
cp -rf ./results/out ./resultVisualizer/src/results
cp ./results/out/builds.json ./resultVisualizer/src/results/builds.json
cp ./results/out/dashboard.json ./resultVisualizer/src/results/dashboard.json
cp ./results/out/config.json ./resultVisualizer/src/config/config.json
cd ./resultVisualizer
npm run build
'''
}
}
}
stage('Deploy'){
steps{
sshagent(['24f0908d-7662-4e93-80cc-1143b7f92ff1']) {
nodejs(nodeJSInstallationName: 'Latest'){
sh '''
cd ./resultVisualizer
npm run deploy
'''
}
}
}
}
}
}