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

.drone.yml 2.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. workspace:
  2. base: /srv/app
  3. path: src/code.gitea.io/gitea
  4. pipeline:
  5. test:
  6. image: webhippie/golang:${GO_VERSION}
  7. pull: true
  8. environment:
  9. CGO_ENABLED: 1
  10. TAGS: cert sqlite pam miniwinsvc
  11. commands:
  12. - apk -U add linux-pam-dev openssh-client
  13. - make clean
  14. - make vet
  15. # - make lint
  16. - make test
  17. - make build
  18. test-mysql:
  19. image: webhippie/golang:${GO_VERSION}
  20. pull: true
  21. commands:
  22. - make test-mysql
  23. when:
  24. event: push
  25. test-pgsql:
  26. image: webhippie/golang:${GO_VERSION}
  27. pull: true
  28. commands:
  29. - make test-pgsql
  30. when:
  31. event: push
  32. updater:
  33. image: karalabe/xgo-latest:latest
  34. pull: true
  35. commands:
  36. - make publish
  37. when:
  38. event: [ push, tag ]
  39. branch: [ master, refs/tags/* ]
  40. matrix:
  41. GO_VERSION: 1.7
  42. coverage:
  43. image: plugins/coverage
  44. server: https://coverage.gitea.io
  45. when:
  46. matrix:
  47. GO_VERSION: 1.7
  48. docker:
  49. image: plugins/docker
  50. repo: gitea/gitea
  51. tags: [ '${TAG}' ]
  52. when:
  53. event: tag
  54. branch: refs/tags/*
  55. matrix:
  56. GO_VERSION: 1.7
  57. docker:
  58. image: plugins/docker
  59. repo: gitea/gitea
  60. tags: [ 'latest' ]
  61. when:
  62. event: push
  63. branch: master
  64. matrix:
  65. GO_VERSION: 1.7
  66. release:
  67. image: plugins/s3
  68. path_style: true
  69. source: dist/release/
  70. target: /lgtm/master
  71. when:
  72. event: push
  73. branch: master
  74. matrix:
  75. GO_VERSION: 1.7
  76. release:
  77. image: plugins/s3
  78. path_style: true
  79. source: dist/release/
  80. target: /lgtm/$$TAG
  81. when:
  82. event: tag
  83. branch: refs/tags/*
  84. matrix:
  85. GO_VERSION: 1.7
  86. latest:
  87. image: plugins/s3
  88. path_style: true
  89. source: dist/latest/
  90. target: /lgtm/latest
  91. when:
  92. event: tag
  93. branch: refs/tags/*
  94. matrix:
  95. GO_VERSION: 1.7
  96. github:
  97. image: plugins/github-release
  98. files:
  99. - dist/release/*
  100. when:
  101. event: tag
  102. branch: refs/tags/*
  103. matrix:
  104. GO_VERSION: 1.7
  105. gitter:
  106. image: plugins/gitter
  107. services:
  108. mysql:
  109. image: mysql:5.7
  110. environment:
  111. - MYSQL_DATABASE=test
  112. - MYSQL_ALLOW_EMPTY_PASSWORD=yes
  113. when:
  114. event: push
  115. pgsql:
  116. image: postgres:9.5
  117. environment:
  118. - POSTGRES_DB=test
  119. when:
  120. event: push
  121. matrix:
  122. GO_VERSION:
  123. - 1.6
  124. - 1.7