You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

.drone.yml 911 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. kind: pipeline
  2. type: docker
  3. name: 1
  4. platform:
  5. os: linux
  6. arch: arm64
  7. volumes:
  8. - name: cache
  9. host:
  10. path: /var/lib/cache
  11. steps:
  12. - name: maventask1
  13. image: maven:3-jdk-10
  14. volumes:
  15. - name: cache
  16. path: /root/.m2
  17. commands:
  18. - echo "clean target"
  19. - name: maventask2
  20. image: maven:3-jdk-10
  21. volumes:
  22. - name: cache
  23. path: /root/.m2
  24. commands:
  25. - echo "install dependency"
  26. - name: maven
  27. image: maven:3-jdk-10
  28. volumes:
  29. - name: cache
  30. path: /root/.m2
  31. commands:
  32. - mvn compile
  33. depends_on:
  34. - maventask1
  35. - maventask2
  36. - name: 远程主机部署
  37. image: appleboy/drone-ssh:linux-arm64
  38. settings:
  39. host:
  40. from_secret: ip
  41. username:
  42. from_secret: name
  43. password:
  44. from_secret: pwd
  45. port: 22
  46. script:
  47. - chmod +x /home/deploy.sh
  48. - nohup bash /home/deploy.sh &
  49. trigger:
  50. branch:
  51. - parallel
  52. event:
  53. - push