This repository has been archived by the owner on Jan 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 265
/
Linux-SGX
executable file
·121 lines (121 loc) · 4.36 KB
/
Linux-SGX
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
pipeline {
agent {
dockerfile { filename 'Jenkinsfiles/ubuntu-16.04.dockerfile'
label 'sgx_slave'
args "-v /lib/modules:/lib/modules:ro -v /usr/src:/usr/src:ro -v /var/run/aesmd/aesm.socket:/var/run/aesmd/aesm.socket --device=/dev/gsgx:/dev/gsgx --device=/dev/isgx:/dev/isgx"
}
}
stages {
stage('Build') {
steps {
sh '''
cd Pal/src/host/Linux-SGX/signer/ && openssl genrsa -3 -out enclave-key.pem 3072
'''
sh '''
cd /opt/intel
git clone https://github.com/01org/linux-sgx-driver.git
cd linux-sgx-driver
git checkout sgx_driver_1.9
make
'''
sh '''
cd Pal/src/host/Linux-SGX/sgx-driver
ISGX_DRIVER_PATH=/opt/intel/linux-sgx-driver ISGX_DRIVER_VERSION=1.9 make
'''
sh '''
make SGX=1
'''
sh '''
make SGX_RUN=1
'''
}
}
stage('Test') {
steps {
/*
timeout(time: 15, unit: 'MINUTES') {
sh '''
cd Pal/regression
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 KEEP_LOG=1 regression
'''
}
*/
timeout(time: 5, unit: 'MINUTES') {
sh '''
cd LibOS/shim/test/regression
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 regression
'''
}
timeout(time: 5, unit: 'MINUTES') {
sh '''
cd LibOS/shim/test/apps/python
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 regression
'''
}
timeout(time: 5, unit: 'MINUTES') {
sh '''
cd LibOS/shim/test/apps/bash
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 regression
'''
}
timeout(time: 5, unit: 'MINUTES') {
sh '''
cd LibOS/shim/test/apps/gcc
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 regression
'''
}
timeout(time: 15, unit: 'MINUTES') {
sh '''
cd LibOS/shim/test/apps/lmbench
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 regression
'''
}
sh '''
cd LibOS/shim/test/apps/lighttpd
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 start-graphene-server &
sleep 10
./benchmark-http.sh `hostname -I|tr -d '[:space:]'`:8000
'''
/*
sh '''
cd LibOS/shim/test/apps/apache
make SGX=1
make SGX_RUN=1
make SGX_RUN=1 start-graphene-server &
sleep 15 && ./benchmark-http.sh `hostname -I|tr -d '[:space:]'`:8001
'''
*/
}
}
stage('Deploy') {
steps {
sh 'echo Deploying code'
}
}
}
post {
success {
echo 'Deployment successful'
}
failure {
echo 'Failure while on the pipeline'
}
unstable {
echo 'Pipeline marked as "unstable"'
}
}
}