Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 
 
 

55 rindas
1.3 KiB

  1. kind: pipeline
  2. type: docker
  3. name: build
  4. clone:
  5. disable: true
  6. steps:
  7. - name: clone
  8. image: docker:git
  9. environment:
  10. KEY:
  11. from_secret: DEPLOY_KEY
  12. PUBLIC:
  13. from_secret: DEPLOY_KEY_PUBLIC
  14. GIT_REPOSITORY:
  15. from_secret: GIT_REPOSITORY
  16. commands:
  17. - eval $(ssh-agent)
  18. - mkdir $HOME/.ssh && echo "$KEY" > $HOME/.ssh/id_rsa && chmod 600 $HOME/.ssh/id_rsa && echo "$PUBLIC" > $HOME/.ssh/id_rsa.pub
  19. - ssh-add $HOME/.ssh/id_rsa
  20. - ssh-keyscan -p 2222 -H gitea.local >> $HOME/.ssh/known_hosts
  21. - git clone $GIT_REPOSITORY ./
  22. - git checkout $DRONE_COMMIT
  23. - name: build_php_base
  24. image: plugins/docker
  25. settings:
  26. dockerfile: docker/php/Dockerfile
  27. registry: registry:5000
  28. repo: registry:5000/arbitry_php_base
  29. insecure: true
  30. build_args:
  31. - PHP_VERSION=7.4.4
  32. depends_on:
  33. - clone
  34. trigger:
  35. status:
  36. - success
  37. - name: build_php_fpm
  38. image: plugins/docker
  39. settings:
  40. dockerfile: docker/php-fpm/Dockerfile
  41. registry: registry:5000
  42. repo: registry:5000/arbitry_php_fpm
  43. insecure: true
  44. build_args:
  45. - BUILD_IMAGE=registry:5000/arbitry_php_base
  46. - PHP_VERSION=7.4.4
  47. depends_on:
  48. - build_php_base
  49. trigger:
  50. status:
  51. - success