Host snippets with a git backend. Like Gists but OpenSource. https://gist.sigpipe.me/
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.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. workspace:
  2. base: /srv/app
  3. path: src/dev.sigpipe.me/dashie/git.txt
  4. clone:
  5. git:
  6. image: plugins/git:1
  7. depth: 50
  8. tags: true
  9. pipeline:
  10. test:
  11. image: webhippie/golang:edge
  12. pull: true
  13. environment:
  14. TAGS: sqlite
  15. GOPATH: /srv/app
  16. commands:
  17. - apk -U add libmagic file-dev libgit2 libgit2-dev
  18. - make test
  19. when:
  20. event: [ push, tag, pull_request ]
  21. build:
  22. image: webhippie/golang:edge
  23. pull: true
  24. environment:
  25. TAGS: sqlite
  26. GOPATH: /srv/app
  27. commands:
  28. - apk -U add libmagic file-dev libgit2 libgit2-dev
  29. - make clean
  30. - make vet
  31. - make lint
  32. - make misspell-check
  33. - make build
  34. when:
  35. event: [ push, tag, pull_request ]
  36. static_Linux_x86_64:
  37. image: webhippie/golang:edge
  38. pull: true
  39. environment:
  40. TAGS: sqlite
  41. GOPATH: /srv/app
  42. commands:
  43. - apk update
  44. - apk -U add libmagic file-dev libgit2 libgit2-dev
  45. - make clean
  46. - make build
  47. - make release-lx64
  48. when:
  49. event: [ push, tag ]
  50. release:
  51. image: plugins/s3
  52. pull: true
  53. secrets: [ aws_access_key_id, aws_secret_access_key ]
  54. bucket: drone-git.txt
  55. region: us-east-1
  56. endpoint: https://s3.sigpipe.me
  57. path_style: true
  58. strip_prefix: dist/release/
  59. source: dist/release/*.tgz
  60. target: /git.txt/${DRONE_TAG##v}
  61. when:
  62. event: [ tag ]
  63. release:
  64. image: plugins/s3
  65. pull: true
  66. secrets: [ aws_access_key_id, aws_secret_access_key ]
  67. bucket: drone-git.txt
  68. region: us-east-1
  69. endpoint: https://s3.sigpipe.me
  70. path_style: true
  71. strip_prefix: dist/release/
  72. source: dist/release/*.tgz
  73. target: /git.txt/master
  74. when:
  75. event: [ push ]
  76. branch: [ master ]
  77. # static:
  78. # image: karalabe/xgo-latest:latest
  79. # pull: true
  80. # environment:
  81. # TAGS: sqlite
  82. # GOPATH: /srv/app
  83. # commands:
  84. # - make clean
  85. # - make release
  86. # when:
  87. # event: [ push, tag ]
  88. #
  89. # release:
  90. # image: plugins/s3:1
  91. # pull: true
  92. # secrets: [ s3_ak, s3_sk ]
  93. # bucket: drone-git.txt
  94. # endpoint: https://s3.sigpipe.me
  95. # path_style: true
  96. # strip_prefix: dist/release/
  97. # source: dist/release/*
  98. # target: /git.txt/${DRONE_TAG##v}
  99. # when:
  100. # event: [ tag ]
  101. #
  102. # release:
  103. # image: plugins/s3:1
  104. # pull: true
  105. # secrets: [ s3_ak, s3_sk ]
  106. # bucket: releases
  107. # endpoint: https://s3.sigpipe.me
  108. # path_style: true
  109. # strip_prefix: dist/release/
  110. # source: dist/release/*
  111. # target: /git.txt/master
  112. # when:
  113. # event: [ push ]
  114. # branch: [ master ]
  115. notify:
  116. image: plugins/slack
  117. channel: gitea
  118. secrets:
  119. - SLACK_WEBHOOK
  120. when:
  121. event: [ push, tag, pull_request ]
  122. status: [ changed, failure, success ]