.drone.yml 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. ---
  2. kind: pipeline
  3. name: wapage2web
  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_REPO: hub.evbj.easou.com
  12. JNLP_TAG: v1base.0.13
  13. JNLP_CONTAINER_PORT: 8080
  14. JNLP_SVC_MODE: http
  15. JNLP_STORAGE_CLASS: rbd
  16. JNLP_DOMAIN: .ieasou.cn
  17. JNLP_CONTROL: StatefulSet
  18. JNLP_REPLICAS: 1
  19. JNLP_STORAGE_CAPACITY: 100Gi
  20. JNLP_MOUNT_PATH: /data
  21. JNLP_LIVENESS_INIT: 60
  22. JNLP_LIVENESS_PER: 10
  23. JNLP_READINESS_INIT: 60
  24. JNLP_READINESS_PER: 10
  25. commands:
  26. - wrapper.sh /bin/sh
  27. - docker --config /etc/docker build -t "$JNLP_REPO/$JNLP_ENV/$DRONE_REPO_NAME:$JNLP_TAG" . -f Dockerfile
  28. - docker --config /etc/docker push "$JNLP_REPO/$JNLP_ENV/$DRONE_REPO_NAME:$JNLP_TAG"
  29. - python ppctl.py -b
  30. - python ppctl.py -a
  31. - python ppctl.py -d
  32. # - python ppctl.py -c
  33. - name: success
  34. image: clem109/drone-wechat
  35. settings:
  36. corpid: ww419ee4063735e1c0
  37. corp_secret: zpiRBLETH9eLwIMQ4eJ_r_dcm3BPSGeLHvTcft8Ot-M
  38. agent_id: 1000004
  39. title: "Pipeline ${DRONE_REPO_NAME} Success"
  40. description: "${DRONE_BUILD_LINK} 部署完成"
  41. msg_url: ${DRONE_BUILD_LINK}
  42. btn_txt: "否"
  43. when:
  44. status:
  45. - success
  46. - name: failure
  47. image: clem109/drone-wechat
  48. settings:
  49. corpid: ww419ee4063735e1c0
  50. corp_secret: zpiRBLETH9eLwIMQ4eJ_r_dcm3BPSGeLHvTcft8Ot-M
  51. agent_id: 1000004
  52. title: "Pipeline ${DRONE_REPO_NAME} Failure"
  53. description: "${DRONE_BUILD_LINK} 部署失败,请检查配置!"
  54. msg_url: ${DRONE_BUILD_LINK}
  55. btn_txt: "否"
  56. when:
  57. status:
  58. - failure