Jenkinsfile 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. pipeline {
  2. agent any
  3. options {
  4. skipDefaultCheckout(true)
  5. }
  6. stages {
  7. stage ('Pre-Build') {
  8. steps {
  9. cleanWs()
  10. checkout scm
  11. sh 'make go-tools'
  12. }
  13. }
  14. stage('Compile') {
  15. steps {
  16. withEnv(["PATH+GO=/root/go/bin/"]) {
  17. sh 'go env'
  18. sh 'echo $PATH'
  19. sh 'buf generate'
  20. sh 'make daemon-compile'
  21. }
  22. }
  23. }
  24. stage ('Post-Compile') {
  25. parallel {
  26. stage('Codestyle') {
  27. steps {
  28. withEnv(["PATH+GO=/root/go/bin/"]) {
  29. sh 'make daemon-codestyle'
  30. sh 'make webui-codestyle'
  31. }
  32. }
  33. }
  34. stage('UnitTests') {
  35. steps {
  36. withEnv(["PATH+GO=/root/go/bin/"]) {
  37. sh 'make daemon-unittests'
  38. }
  39. }
  40. }
  41. }
  42. }
  43. }
  44. }