-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJenkinsfile
More file actions
47 lines (42 loc) · 1.32 KB
/
Jenkinsfile
File metadata and controls
47 lines (42 loc) · 1.32 KB
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
pipeline {
// Run this pipeline on your local Mac environment
agent any
stages {
stage('Environment Check') {
steps {
echo ' Checking what tools are available on my Mac...'
sh 'sw_vers' // Prints your macOS version
sh 'git --version' // Prints your local Git version
}
}
stage('Build') {
steps {
echo '🔨 Simulating a build phase...'
// If you are using Node, you could run: sh 'npm install'
sh 'echo "Compile complete!"'
}
}
stage('Test') {
steps {
echo '🧪 Running automated tests...'
// Example: sh 'npm test' or custom test scripts
sh 'echo "All tests passed successfully!"'
}
}
stage('Deploy') {
steps {
echo '🚀 Deploying locally...'
sh 'echo "Application deployed successfully to localhost!"'
}
}
}
// This section runs automatically after the stages complete
post {
success {
echo '🎉 Success! The entire pipeline completed cleanly.'
}
failure {
echo '❌ Uh oh! Something in the pipeline broke.'
}
}
}