.drone.yml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. ---
  2. kind: pipeline
  3. name: wapage2misc
  4. steps:
  5. - name: build
  6. image: hub.evbj.easou.com/dev/drone-agent-custom:v5.0.0
  7. # pull: always
  8. privileged: true
  9. environment:
  10. JNLP_ENV: qa
  11. JNLP_REPLICAS: 2
  12. JNLP_TAG: v1base0.0.1
  13. JNLP_REPO: hub.evbj.easou.com
  14. JNLP_CONTAINER_PORT: 9001
  15. JNLP_INGRESS: nginx
  16. JNLP_SVC_MODE: http
  17. JNLP_STORAGE_CLASS: rbd
  18. JNLP_DOMAIN: .ieasou.cn
  19. JNLP_CONTROL: StatefulSet
  20. JNLP_STORAGE_CAPACITY: 200Gi
  21. JNLP_MOUNT_PATH: /data
  22. JNLP_LIVENESS_INIT: 60
  23. JNLP_LIVENESS_PER: 10
  24. JNLP_READINESS_INIT: 60
  25. JNLP_READINESS_PER: 10
  26. commands:
  27. - wrapper.sh /bin/sh
  28. - docker --config /etc/docker build -t "$JNLP_REPO/$JNLP_ENV/$DRONE_REPO_NAME:$JNLP_TAG" . -f Dockerfile
  29. - docker --config /etc/docker push "$JNLP_REPO/$JNLP_ENV/$DRONE_REPO_NAME:$JNLP_TAG"
  30. - python ppctl.py -b
  31. - python ppctl.py -a
  32. - python ppctl.py -d
  33. # - python ppctl.py -c
  34. - name: success
  35. image: clem109/drone-wechat
  36. settings:
  37. corpid: ww419ee4063735e1c0
  38. corp_secret: zpiRBLETH9eLwIMQ4eJ_r_dcm3BPSGeLHvTcft8Ot-M
  39. agent_id: 1000004
  40. title: "Pipeline ${DRONE_REPO_NAME} Success"
  41. description: "${DRONE_BUILD_LINK} 部署完成"
  42. msg_url: ${DRONE_BUILD_LINK}
  43. btn_txt: "否"
  44. when:
  45. status:
  46. - success
  47. - name: failure
  48. image: clem109/drone-wechat
  49. settings:
  50. corpid: ww419ee4063735e1c0
  51. corp_secret: zpiRBLETH9eLwIMQ4eJ_r_dcm3BPSGeLHvTcft8Ot-M
  52. agent_id: 1000004
  53. title: "Pipeline ${DRONE_REPO_NAME} Failure"
  54. description: "${DRONE_BUILD_LINK} 部署失败,请检查配置!"
  55. msg_url: ${DRONE_BUILD_LINK}
  56. btn_txt: "否"
  57. when:
  58. status:
  59. - failure