forked from LandmakTechnology/nodejs-application
-
Notifications
You must be signed in to change notification settings - Fork 0
/
scriptedfile
38 lines (37 loc) · 959 Bytes
/
scriptedfile
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
node{
stage('CodeCheckout'){
sh "echo running ebay nodeJS project"
git 'https://github.com/Aminaa-a/nodejs-application'
}
stage('UnitTest'){
sh "echo unir npm test"
//sh "npm test"
}
stage('Build'){
sh "echo creating build artifacts"
//nodejs(nodeJSInstallationName: 'NodeJS20.7.0') {
sh 'npm install'
//}
}
stage('Quality'){
sh "echo CodeQualityReport"
//nodejs(nodeJSInstallationName: 'NodeJS20.7.0') {
sh 'npm run sonar'
//}
}
stage('UploadArtifacts'){
sh "echo npm packages uploaded"
//nodejs(nodeJSInstallationName: 'NodeJS20.7.0') {
sh 'npm publish'
// Jenkins nexus intergration
// password = admin123 username = admin
// echo -n 'admin:admin123' | openssl base64
//}
}
stage('deployment'){
sh "echo Deploying applications"
//nodejs(nodeJSInstallationName: 'NodeJS20.7.0') {
//sh 'npm start'
//}
}
}