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.

.cirrus.yml 16KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467
  1. # content of service-account-credentials.json, used to access to Google Cloud Platform
  2. gcp_credentials: ENCRYPTED[534d4b89444f3e4e3ba299769a98010609e71992355c132fd6e448f1d8fcb039184224c8b4cdf7933b0aec16d6a8896d]
  3. env:
  4. GRADLE_OPTS: -Dorg.gradle.daemon=false -Dorg.gradle.jvmargs="-XX:+PrintFlagsFinal -XshowSettings:vm -XX:+HeapDumpOnOutOfMemoryError -XX:+UnlockExperimentalVMOptions -Djava.security.egd=file:/dev/./urandom -Dfile.encoding=UTF8 -Duser.language=en -Duser.country=US"
  5. # to be replaced by other credentials
  6. ARTIFACTORY_PRIVATE_USERNAME: ENCRYPTED[c0baa3376daa1e08d602435081d07653799cf34ab09ca92e575f3dc4176bc6cf2ebf87120e83f3aa6804f072013e8e2b]
  7. ARTIFACTORY_PRIVATE_PASSWORD: ENCRYPTED[f13d32d218c3da8008114d2c8857b2956047fbdab2163bbf186b8b89f789f0efa7504f499749a59ad5988c14e5360353]
  8. ARTIFACTORY_DEPLOY_USERNAME: public-qa-deployer
  9. ARTIFACTORY_DEPLOY_PASSWORD: ENCRYPTED[9362d735843b21b375b6e19d91e0de5216e053e229e39e2ce33a0c866306e6e3f9b08db8a0e126ca5e986fea97e975fd]
  10. ARTIFACTORY_DEPLOY_USERNAME_PRIVATE: private-qa-deployer
  11. ARTIFACTORY_DEPLOY_PASSWORD_PRIVATE: ENCRYPTED[61769719e9b775afe103dbee22141eeaa0116b3332eafb993be2a5919ff7bf017cdc519afed07dc6cac8ebbc0846f191]
  12. ARTIFACTORY_API_KEY: ENCRYPTED[d52910db749f2678f43084b18c849486d68fbc02c2f5489c7ee1085c395de9dc7575313a8b348bb5361a693dd782e07e]
  13. # download licenses for testing commercial editions
  14. GITHUB_TOKEN: ENCRYPTED[bd3d5f7fe5901d9d9f2564caebb52af285262177294eae67ba5f1a3a1df1316449ce6e09c5e1b68eeff37e024e2d167a]
  15. # notifications to burgr
  16. BURGR_URL: ENCRYPTED[06b8fcc9aaa4b495043aa08bc4450b89588902ad9a60cc8525f53d14810aff84558812e4b7eb01131dd64f33916ac941]
  17. BURGR_USERNAME: ENCRYPTED[cf7bfb936025fb763013bbfef0ab5723c0d9b53f135d79af36f9defa933f4b5fc72842bd83a97ce9b614503c1b77e6da]
  18. BURGR_PASSWORD: ENCRYPTED[bc554fc6a06c9f14cc9924cefad0a69e962a905b6d1609fc9357d458b45fc52ac74c960ad9c7382a0691433fa9dcd483]
  19. # ops-jenkins credentials required to trigger docs deppoyment
  20. OPS_JENKINS_URL: ENCRYPTED[00ea2b88c762e374c02a3d29a306cc1cf3ceb4b3d807bda2a601486e0d483fd67a556ef295830231390f45e7d512b54d]
  21. OPS_JENKINS_USERNAME: ENCRYPTED[c778b1483a7ca000dc760ef731c2fbe1dc05a9af38f2a85206cfbcdf649e50715ca447ac291485d513aa9120b0c9abad]
  22. OPS_JENKINS_PASSWORD: ENCRYPTED[a035a2826c3bc971288284a59bd00dda193d8a81e7809e08bf4ec59b68894c16f30095a567e65755240bb7f919c2e0bf]
  23. # DOCS_JOB_TOKEN: token required to launch the deployment of documentation job on ops-jenkins (see private/cirrus/cirrus-trigger-deploy-docs.sh)
  24. DOCS_JOB_TOKEN: ENCRYPTED[7771f76a0fc0038f9929c32d98588963c8dcda6148ba054f57358bc17faa109ac638134c89067f3bacc8933d2fa2c541]
  25. # analysis on next.sonarqube.com
  26. SONARQUBE_NEXT_TOKEN: ENCRYPTED[e3d98fa0ecceb015e9803d47f78c3040f5a710d678a631107635d69f650d4e53ecaf2e2334cc1fe0c47037ec915dcda0]
  27. auto_cancellation: $CIRRUS_BRANCH != 'master' && $CIRRUS_BRANCH !=~ 'branch.*' && $CIRRUS_BRANCH != 'dogfood-on-next'
  28. build_task:
  29. only_if: $CIRRUS_BRANCH !=~ "dogfood/.*" && $CIRRUS_BRANCH != "public_master"
  30. timeout_in: 90m
  31. gke_container:
  32. dockerfile: private/docker/Dockerfile-build
  33. builder_image_project: ci-cd-215716
  34. builder_image_name: docker-builder-v1
  35. cluster_name: cirrus-euw3a-cluster
  36. zone: europe-west3-a
  37. namespace: default
  38. cpu: 3
  39. memory: 10Gb
  40. gradle_cache:
  41. folder: ~/.gradle/caches
  42. env:
  43. # No need to clone the full history.
  44. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  45. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  46. CIRRUS_CLONE_DEPTH: 50
  47. script:
  48. - ./private/cirrus/cirrus-build.sh
  49. cleanup_before_cache_script:
  50. - ./private/cirrus/cleanup-gradle-cache.sh
  51. on_failure:
  52. reports_artifacts:
  53. path: "**/build/reports/**/*"
  54. deploy_docs_task:
  55. depends_on: build
  56. only_if: $CIRRUS_BRANCH == 'dogfood-on-next'
  57. gke_container:
  58. dockerfile: private/docker/Dockerfile-build
  59. builder_image_project: ci-cd-215716
  60. builder_image_name: docker-builder-v1
  61. cluster_name: cirrus-euw3a-cluster
  62. zone: europe-west3-a
  63. namespace: default
  64. cpu: 1
  65. memory: 1Gb
  66. env:
  67. # No need to clone the full history.
  68. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  69. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  70. CIRRUS_CLONE_DEPTH: 50
  71. script:
  72. - ./private/cirrus/cirrus-trigger-deploy-docs.sh
  73. validate_task:
  74. depends_on: build
  75. only_if: $CIRRUS_BRANCH !=~ "dogfood/.*" && $CIRRUS_BRANCH != "public_master" && $CIRRUS_TAG != "nightly-build"
  76. timeout_in: 90m
  77. gke_container:
  78. dockerfile: private/docker/Dockerfile-build
  79. builder_image_project: ci-cd-215716
  80. builder_image_name: docker-builder-v1
  81. cluster_name: cirrus-euw3a-cluster
  82. zone: europe-west3-a
  83. namespace: default
  84. cpu: 2.4
  85. memory: 10Gb
  86. additional_containers:
  87. - name: postgres
  88. image: postgres:10.6
  89. port: 5432
  90. cpu: 1
  91. memory: 1Gb
  92. env:
  93. POSTGRES_USER: postgres
  94. POSTGRES_PASSWORD: postgres
  95. gradle_cache:
  96. folder: ~/.gradle/caches
  97. script:
  98. - ./private/cirrus/cirrus-validate.sh postgres106
  99. cleanup_before_cache_script:
  100. - ./private/cirrus/cleanup-gradle-cache.sh
  101. on_failure:
  102. reports_artifacts:
  103. path: "**/build/reports/**/*"
  104. qa_task:
  105. depends_on: build
  106. only_if: $CIRRUS_BRANCH !=~ "dogfood/.*" && $CIRRUS_BRANCH != "public_master" && $CIRRUS_TAG != "nightly-build"
  107. gke_container:
  108. dockerfile: private/docker/Dockerfile-build
  109. builder_image_project: ci-cd-215716
  110. builder_image_name: docker-builder-v1
  111. cluster_name: cirrus-euw3a-cluster
  112. zone: europe-west3-a
  113. namespace: default
  114. cpu: 2.4
  115. memory: 10Gb
  116. additional_containers:
  117. - name: postgres
  118. image: postgres:10.6
  119. port: 5432
  120. cpu: 1
  121. memory: 1Gb
  122. env:
  123. POSTGRES_USER: postgres
  124. POSTGRES_PASSWORD: postgres
  125. env:
  126. # No need to clone the full history.
  127. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  128. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  129. CIRRUS_CLONE_DEPTH: 50
  130. matrix:
  131. QA_CATEGORY: Cat1
  132. QA_CATEGORY: Cat2
  133. QA_CATEGORY: Cat3
  134. QA_CATEGORY: Cat4
  135. QA_CATEGORY: Cat5
  136. QA_CATEGORY: Cat6
  137. QA_CATEGORY: Cat7
  138. QA_CATEGORY: Gov
  139. QA_CATEGORY: Billing
  140. QA_CATEGORY: License
  141. QA_CATEGORY: Branch
  142. QA_CATEGORY: Upgrade
  143. gradle_cache:
  144. folder: ~/.gradle/caches
  145. script:
  146. - ./private/cirrus/cirrus-qa.sh postgres106
  147. cleanup_before_cache_script:
  148. - ./private/cirrus/cleanup-gradle-cache.sh
  149. on_failure:
  150. reports_artifacts:
  151. path: "**/build/reports/**/*"
  152. promote_task:
  153. depends_on:
  154. - build
  155. - validate
  156. - qa
  157. only_if: $CIRRUS_BRANCH !=~ "dogfood/.*" && $CIRRUS_BRANCH != "public_master" && $CIRRUS_TAG != "nightly-build"
  158. gke_container:
  159. dockerfile: private/docker/Dockerfile-build
  160. builder_image_project: ci-cd-215716
  161. builder_image_name: docker-builder-v1
  162. cluster_name: cirrus-euw3a-cluster
  163. zone: europe-west3-a
  164. namespace: default
  165. cpu: 1
  166. memory: 1Gb
  167. env:
  168. # No need to clone the full history.
  169. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  170. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  171. CIRRUS_CLONE_DEPTH: 50
  172. script:
  173. - ./private/cirrus/cirrus-promote.sh
  174. test_sql_mysql57_task:
  175. depends_on: build
  176. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  177. # this task on your branch
  178. only_if: $CIRRUS_TAG == "nightly-build"
  179. gke_container:
  180. image: gradle:4.10.1-jdk8
  181. cluster_name: cirrus-euw3a-cluster
  182. zone: europe-west3-a
  183. namespace: default
  184. cpu: 1
  185. memory: 10Gb
  186. additional_containers:
  187. - name: mysql
  188. image: mysql:5.7 # see https://github.com/mysql/mysql-docker
  189. port: 3306
  190. cpu: 1
  191. memory: 1Gb
  192. env:
  193. MYSQL_ROOT_PASSWORD: sonarsource
  194. MYSQL_DATABASE: sonar
  195. MYSQL_USER: sonar
  196. MYSQL_PASSWORD: sonar
  197. gradle_cache:
  198. folder: ~/.gradle/caches
  199. script:
  200. - ./private/cirrus/cirrus-db-unit-test.sh mysql57
  201. cleanup_before_cache_script:
  202. - ./private/cirrus/cleanup-gradle-cache.sh
  203. on_failure:
  204. reports_artifacts:
  205. path: "**/build/reports/**/*"
  206. test_sql_mssql2017_task:
  207. depends_on: build
  208. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  209. # this task on your branch
  210. only_if: $CIRRUS_TAG == "nightly-build"
  211. gke_container:
  212. image: gradle:4.10.1-jdk8
  213. cluster_name: cirrus-euw3a-cluster
  214. zone: europe-west3-a
  215. namespace: default
  216. cpu: 1
  217. memory: 5Gb
  218. additional_containers:
  219. - name: mssql
  220. image: mcr.microsoft.com/mssql/server:2017-CU12-ubuntu
  221. port: 1433
  222. cpu: 2
  223. memory: 5Gb
  224. env:
  225. MSSQL_PID: Developer # this is the default edition
  226. ACCEPT_EULA: Y
  227. SA_PASSWORD: sonarqube!1
  228. gradle_cache:
  229. folder: ~/.gradle/caches
  230. script:
  231. - ./private/cirrus/cirrus-db-unit-test.sh mssql2017
  232. cleanup_before_cache_script:
  233. - ./private/cirrus/cleanup-gradle-cache.sh
  234. on_failure:
  235. reports_artifacts:
  236. path: "**/build/reports/**/*"
  237. test_sql_mssql2019_task:
  238. depends_on: build
  239. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  240. # this task on your branch
  241. only_if: $CIRRUS_TAG == "nightly-build"
  242. gke_container:
  243. image: gradle:4.10.1-jdk8
  244. cluster_name: cirrus-euw3a-cluster
  245. zone: europe-west3-a
  246. namespace: default
  247. cpu: 1
  248. memory: 5Gb
  249. additional_containers:
  250. - name: mssql
  251. image: mcr.microsoft.com/mssql/server:2019-CTP2.2-ubuntu
  252. port: 1433
  253. cpu: 2
  254. memory: 5Gb
  255. env:
  256. MSSQL_PID: Developer # this is the default edition
  257. ACCEPT_EULA: Y
  258. SA_PASSWORD: sonarqube!1
  259. gradle_cache:
  260. folder: ~/.gradle/caches
  261. script:
  262. - ./private/cirrus/cirrus-db-unit-test.sh mssql2019
  263. cleanup_before_cache_script:
  264. - ./private/cirrus/cleanup-gradle-cache.sh
  265. on_failure:
  266. reports_artifacts:
  267. path: "**/build/reports/**/*"
  268. # this is the oldest compatible version of PostgreSQL
  269. test_sql_postgres93_task:
  270. depends_on: build
  271. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  272. # this task on your branch
  273. only_if: $CIRRUS_TAG == "nightly-build"
  274. gke_container:
  275. image: gradle:4.10.1-jdk8
  276. cluster_name: cirrus-euw3a-cluster
  277. zone: europe-west3-a
  278. namespace: default
  279. cpu: 1
  280. memory: 5Gb
  281. additional_containers:
  282. - name: postgres
  283. image: postgres:9.3
  284. port: 5432
  285. cpu: 1
  286. memory: 1Gb
  287. env:
  288. POSTGRES_USER: postgres
  289. POSTGRES_PASSWORD: postgres
  290. gradle_cache:
  291. folder: ~/.gradle/caches
  292. script:
  293. - ./private/cirrus/cirrus-db-unit-test.sh postgres93
  294. cleanup_before_cache_script:
  295. - ./private/cirrus/cleanup-gradle-cache.sh
  296. on_failure:
  297. reports_artifacts:
  298. path: "**/build/reports/**/*"
  299. test_sql_oracle12_task:
  300. depends_on: build
  301. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  302. # this task on your branch
  303. only_if: $CIRRUS_TAG == "nightly-build"
  304. gke_container:
  305. image: gradle:4.10.1-jdk8
  306. cluster_name: cirrus-euw3a-cluster
  307. zone: europe-west3-a
  308. namespace: default
  309. cpu: 1
  310. memory: 5Gb
  311. additional_containers:
  312. - name: oracle
  313. image: gcr.io/ci-cd-215716/oracle12:0.0.1 # see https://github.com/SonarSource/vms/blob/master/docker/README.md#oracle-12c to build it
  314. port: 1521
  315. cpu: 2
  316. memory: 5Gb
  317. env:
  318. ORACLE_PWD: sonarqube
  319. gradle_cache:
  320. folder: ~/.gradle/caches
  321. script:
  322. - ./private/cirrus/cirrus-db-unit-test.sh oracle12
  323. cleanup_before_cache_script:
  324. - ./private/cirrus/cleanup-gradle-cache.sh
  325. on_failure:
  326. reports_artifacts:
  327. path: "**/build/reports/**/*"
  328. test_upgrade_mysql57_task:
  329. depends_on: build
  330. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  331. # this task on your branch
  332. only_if: $CIRRUS_TAG == "nightly-build"
  333. gke_container:
  334. dockerfile: private/docker/Dockerfile-build
  335. builder_image_project: ci-cd-215716
  336. builder_image_name: docker-builder-v1
  337. cluster_name: cirrus-euw3a-cluster
  338. zone: europe-west3-a
  339. namespace: default
  340. cpu: 1.5
  341. memory: 6Gb
  342. additional_containers:
  343. - name: mysql
  344. image: mysql:5.7 # see https://github.com/mysql/mysql-docker
  345. port: 3306
  346. cpu: 1
  347. memory: 1Gb
  348. env:
  349. MYSQL_ROOT_PASSWORD: sonarsource
  350. MYSQL_DATABASE: sonar
  351. MYSQL_USER: sonar
  352. MYSQL_PASSWORD: sonar
  353. env:
  354. # No need to clone the full history.
  355. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  356. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  357. CIRRUS_CLONE_DEPTH: 50
  358. matrix:
  359. QA_CATEGORY: Upgrade
  360. gradle_cache:
  361. folder: ~/.gradle/caches
  362. script:
  363. - ./private/cirrus/cirrus-qa.sh mysql57
  364. cleanup_before_cache_script:
  365. - ./private/cirrus/cleanup-gradle-cache.sh
  366. on_failure:
  367. reports_artifacts:
  368. path: "**/build/reports/**/*"
  369. test_upgrade_mssql2017_task:
  370. depends_on: build
  371. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  372. # this task on your branch
  373. only_if: $CIRRUS_TAG == "nightly-build"
  374. gke_container:
  375. dockerfile: private/docker/Dockerfile-build
  376. builder_image_project: ci-cd-215716
  377. builder_image_name: docker-builder-v1
  378. cluster_name: cirrus-euw3a-cluster
  379. zone: europe-west3-a
  380. namespace: default
  381. cpu: 1.5
  382. memory: 6Gb
  383. additional_containers:
  384. - name: mssql
  385. image: mcr.microsoft.com/mssql/server:2017-CU12-ubuntu
  386. port: 1433
  387. cpu: 2
  388. memory: 5Gb
  389. env:
  390. MSSQL_PID: Developer # this is the default edition
  391. ACCEPT_EULA: Y
  392. SA_PASSWORD: sonarqube!1
  393. env:
  394. # No need to clone the full history.
  395. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  396. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  397. CIRRUS_CLONE_DEPTH: 50
  398. matrix:
  399. QA_CATEGORY: Upgrade
  400. gradle_cache:
  401. folder: ~/.gradle/caches
  402. script:
  403. - ./private/cirrus/cirrus-qa.sh mssql2017
  404. cleanup_before_cache_script:
  405. - ./private/cirrus/cleanup-gradle-cache.sh
  406. on_failure:
  407. reports_artifacts:
  408. path: "**/build/reports/**/*"
  409. test_upgrade_oracle12_task:
  410. depends_on: build
  411. # Comment the following line and commit with message "DO NOT MERGE" in order to run
  412. # this task on your branch
  413. only_if: $CIRRUS_TAG == "nightly-build"
  414. gke_container:
  415. dockerfile: private/docker/Dockerfile-build
  416. builder_image_project: ci-cd-215716
  417. builder_image_name: docker-builder-v1
  418. cluster_name: cirrus-euw3a-cluster
  419. zone: europe-west3-a
  420. namespace: default
  421. cpu: 1.5
  422. memory: 6Gb
  423. additional_containers:
  424. - name: oracle
  425. image: gcr.io/ci-cd-215716/oracle12:0.0.1 # see https://github.com/SonarSource/vms/blob/master/docker/README.md#oracle-12c to build it
  426. port: 1521
  427. cpu: 2
  428. memory: 5Gb
  429. env:
  430. ORACLE_PWD: sonarqube
  431. env:
  432. # No need to clone the full history.
  433. # Depth of 1 is not enough because it would fail the build in case of consecutive pushes
  434. # (example of error: "Hard resetting to c968ecaf7a1942dacecd78480b3751ac74d53c33...Failed to force reset to c968ecaf7a1942dacecd78480b3751ac74d53c33: object not found!")
  435. CIRRUS_CLONE_DEPTH: 50
  436. matrix:
  437. QA_CATEGORY: Upgrade
  438. gradle_cache:
  439. folder: ~/.gradle/caches
  440. script:
  441. - ./private/cirrus/cirrus-qa.sh oracle12
  442. cleanup_before_cache_script:
  443. - ./private/cirrus/cleanup-gradle-cache.sh
  444. on_failure:
  445. reports_artifacts:
  446. path: "**/build/reports/**/*"