Handy UI for browsing the /tg/station wiki while powergaming
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.
 
 
 
 

149 lines
3.0 KiB

  1. ---
  2. kind: pipeline
  3. name: default
  4. steps:
  5. - name: restore-cache
  6. image: drillster/drone-volume-cache
  7. volumes:
  8. - name: cache
  9. path: /cache
  10. settings:
  11. restore: true
  12. mount:
  13. - ./node_modules
  14. - name: dependencies
  15. image: node
  16. failure: ignore
  17. commands:
  18. - yarn
  19. depends_on:
  20. - restore-cache
  21. - name: lint
  22. image: node
  23. commands:
  24. - yarn lint
  25. depends_on:
  26. - dependencies
  27. - name: build_versioned
  28. image: node
  29. commands:
  30. - yarn build
  31. environment:
  32. SUBPATH: /tghandbook/${DRONE_COMMIT_BRANCH/\//_}-${DRONE_COMMIT_SHA:0:8}
  33. REVISION: ${DRONE_COMMIT_SHA}
  34. when:
  35. event:
  36. - push
  37. depends_on:
  38. - dependencies
  39. - name: build_pr
  40. image: node
  41. commands:
  42. - yarn build
  43. environment:
  44. SUBPATH: /tghandbook/pr-${DRONE_PULL_REQUEST}
  45. OUTDIR: ./dist-pr
  46. REVISION: ${DRONE_COMMIT_SHA}
  47. when:
  48. event:
  49. - pull_request
  50. depends_on:
  51. - dependencies
  52. - name: build_branch
  53. image: node
  54. commands:
  55. - yarn build
  56. environment:
  57. SUBPATH: /tghandbook/${DRONE_COMMIT_BRANCH/\//_}
  58. OUTDIR: ./dist-branch
  59. REVISION: ${DRONE_COMMIT_SHA}
  60. when:
  61. event:
  62. - push
  63. depends_on:
  64. - dependencies
  65. - name: upload_build_versioned
  66. image: plugins/s3
  67. settings:
  68. bucket: tghandbook
  69. access_key:
  70. from_secret: minio_access
  71. secret_key:
  72. from_secret: minio_secret
  73. source: dist/**/*
  74. target: /${DRONE_COMMIT_BRANCH/\//_}-${DRONE_COMMIT_SHA:0:8}/
  75. strip_prefix: dist/
  76. path_style: true
  77. endpoint: https://artifacts.fromouter.space
  78. when:
  79. event:
  80. - push
  81. depends_on:
  82. - build_versioned
  83. - name: upload_build_pr
  84. image: plugins/s3
  85. settings:
  86. bucket: tghandbook
  87. access_key:
  88. from_secret: minio_access
  89. secret_key:
  90. from_secret: minio_secret
  91. source: dist-pr/**/*
  92. target: /pr-${DRONE_PULL_REQUEST}/
  93. strip_prefix: dist-pr/
  94. path_style: true
  95. endpoint: https://artifacts.fromouter.space
  96. when:
  97. event:
  98. - pull_request
  99. depends_on:
  100. - build_pr
  101. - name: upload_build_branch
  102. image: plugins/s3
  103. settings:
  104. bucket: tghandbook
  105. access_key:
  106. from_secret: minio_access
  107. secret_key:
  108. from_secret: minio_secret
  109. source: dist-branch/**/*
  110. target: /${DRONE_COMMIT_BRANCH/\//_}/
  111. strip_prefix: dist-branch/
  112. path_style: true
  113. endpoint: https://artifacts.fromouter.space
  114. when:
  115. event:
  116. - push
  117. depends_on:
  118. - build_branch
  119. - name: rebuild-cache
  120. image: drillster/drone-volume-cache
  121. failure: ignore
  122. volumes:
  123. - name: cache
  124. path: /cache
  125. settings:
  126. rebuild: true
  127. mount:
  128. - ./node_modules
  129. depends_on:
  130. - dependencies
  131. volumes:
  132. - name: cache
  133. host:
  134. path: /opt/gitea/drone-cache/hamcha/tghandbook
  135. ---
  136. kind: signature
  137. hmac: 55dfd5c47c79e51394c5cdfaa9b98a6f6acd84e751e92964c202ac19b46c0373