diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 00000000..4da9c2a5 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,39 @@ +pipeline { + agent any + + stages { + stage('Checkout') { + steps { + checkout scm + } + } + + stage('Build Go Application') { + steps { + sh 'go get -u github.com/bettercap/bettercap' + sh 'go build -o myapp main.go' + } + } + + stage('Run Bettercap') { + steps { + sh './bettercap ' + } + } + + stage('Publish Artifacts') { + steps { + archiveArtifacts artifacts: 'myapp' + } + } + } + + post { + success { + echo 'Build successful!' + } + failure { + echo 'Build failed!' + } + } +}