您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
4 年前
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. kind: pipeline
  2. type: docker
  3. name: build
  4. clone:
  5. disable: true
  6. workspace:
  7. base: /drone
  8. path: src
  9. steps:
  10. - name: restore_cache
  11. image: drillster/drone-volume-cache
  12. volumes:
  13. - name: cache
  14. path: /tmp/drone-cache
  15. settings:
  16. restore: true
  17. mount:
  18. - /drone/docker
  19. - name: clone
  20. image: docker:git
  21. depends_on:
  22. - restore_cache
  23. environment:
  24. KEY:
  25. from_secret: DEPLOY_KEY
  26. PUBLIC:
  27. from_secret: DEPLOY_KEY_PUBLIC
  28. GIT_HOST:
  29. from_secret: GIT_HOST
  30. GIT_PORT:
  31. from_secret: GIT_PORT
  32. GIT_REPOSITORY:
  33. from_secret: GIT_REPOSITORY
  34. commands:
  35. - eval $(ssh-agent)
  36. - mkdir $HOME/.ssh && echo "$KEY" > $HOME/.ssh/id_rsa && chmod 600 $HOME/.ssh/id_rsa && echo "$PUBLIC" > $HOME/.ssh/id_rsa.pub
  37. - ssh-add $HOME/.ssh/id_rsa
  38. - ssh-keyscan -p $GIT_PORT -H $GIT_HOST > $HOME/.ssh/known_hosts
  39. - git clone $GIT_REPOSITORY arbitry
  40. - cd arbitry && git checkout $DRONE_BRANCH && rm -rf .git
  41. - name: build_php_base
  42. image: plugins/docker
  43. privileged: true
  44. settings:
  45. #storage_driver: overlay2
  46. storage_path: /drone/docker
  47. use_cache: true
  48. dockerfile: arbitry/docker/php/Dockerfile
  49. context: arbitry
  50. registry: registry:5000
  51. repo: registry:5000/arbitry_php_base
  52. tags: ${DRONE_BRANCH//\\//-}
  53. insecure: true
  54. build_args:
  55. - PHP_VERSION=7.4.4
  56. depends_on:
  57. - clone
  58. trigger:
  59. status:
  60. - success
  61. - name: build_php_fpm
  62. image: plugins/docker
  63. privileged: true
  64. settings:
  65. #storage_driver: overlay2
  66. storage_path: /drone/docker
  67. use_cache: true
  68. dockerfile: arbitry/docker/php-fpm/Dockerfile
  69. registry: registry:5000
  70. repo: registry:5000/arbitry_php_fpm
  71. tags: ${DRONE_BRANCH//\\//-}
  72. insecure: true
  73. build_args:
  74. - BUILD_IMAGE=registry:5000/arbitry_php_base:${DRONE_BRANCH//\\//-}
  75. - PHP_VERSION=7.4.4
  76. depends_on:
  77. - build_php_base
  78. trigger:
  79. status:
  80. - success
  81. - name: rebuild_cache
  82. image: drillster/drone-volume-cache
  83. depends_on:
  84. - build_php_fpm
  85. volumes:
  86. - name: cache
  87. path: /tmp/drone-cache
  88. settings:
  89. rebuild: true
  90. mount:
  91. - /drone/docker