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.

670 lines
16 KiB

8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
contiv network support (#1914) * Add Contiv support Contiv is a network plugin for Kubernetes and Docker. It supports vlan/vxlan/BGP/Cisco ACI technologies. It support firewall policies, multiple networks and bridging pods onto physical networks. * Update contiv version to 1.1.4 Update contiv version to 1.1.4 and added SVC_SUBNET in contiv-config. * Load openvswitch module to workaround on CentOS7.4 * Set contiv cni version to 0.1.0 Correct contiv CNI version to 0.1.0. * Use kube_apiserver_endpoint for K8S_API_SERVER Use kube_apiserver_endpoint as K8S_API_SERVER to make contiv talks to a available endpoint no matter if there's a loadbalancer or not. * Make contiv use its own etcd Before this commit, contiv is using a etcd proxy mode to k8s etcd, this work fine when the etcd hosts are co-located with contiv etcd proxy, however the k8s peering certs are only in etcd group, as a result the etcd-proxy is not able to peering with the k8s etcd on etcd group, plus the netplugin is always trying to find the etcd endpoint on localhost, this will cause problem for all netplugins not runnign on etcd group nodes. This commit make contiv uses its own etcd, separate from k8s one. on kube-master nodes (where net-master runs), it will run as leader mode and on all rest nodes it will run as proxy mode. * Use cp instead of rsync to copy cni binaries Since rsync has been removed from hyperkube, this commit changes it to use cp instead. * Make contiv-etcd able to run on master nodes * Add rbac_enabled flag for contiv pods * Add contiv into CNI network plugin lists * migrate contiv test to tests/files Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> * Add required rules for contiv netplugin * Better handling json return of fwdMode * Make contiv etcd port configurable * Use default var instead of templating * roles/download/defaults/main.yml: use contiv 1.1.7 Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
7 years ago
contiv network support (#1914) * Add Contiv support Contiv is a network plugin for Kubernetes and Docker. It supports vlan/vxlan/BGP/Cisco ACI technologies. It support firewall policies, multiple networks and bridging pods onto physical networks. * Update contiv version to 1.1.4 Update contiv version to 1.1.4 and added SVC_SUBNET in contiv-config. * Load openvswitch module to workaround on CentOS7.4 * Set contiv cni version to 0.1.0 Correct contiv CNI version to 0.1.0. * Use kube_apiserver_endpoint for K8S_API_SERVER Use kube_apiserver_endpoint as K8S_API_SERVER to make contiv talks to a available endpoint no matter if there's a loadbalancer or not. * Make contiv use its own etcd Before this commit, contiv is using a etcd proxy mode to k8s etcd, this work fine when the etcd hosts are co-located with contiv etcd proxy, however the k8s peering certs are only in etcd group, as a result the etcd-proxy is not able to peering with the k8s etcd on etcd group, plus the netplugin is always trying to find the etcd endpoint on localhost, this will cause problem for all netplugins not runnign on etcd group nodes. This commit make contiv uses its own etcd, separate from k8s one. on kube-master nodes (where net-master runs), it will run as leader mode and on all rest nodes it will run as proxy mode. * Use cp instead of rsync to copy cni binaries Since rsync has been removed from hyperkube, this commit changes it to use cp instead. * Make contiv-etcd able to run on master nodes * Add rbac_enabled flag for contiv pods * Add contiv into CNI network plugin lists * migrate contiv test to tests/files Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> * Add required rules for contiv netplugin * Better handling json return of fwdMode * Make contiv etcd port configurable * Use default var instead of templating * roles/download/defaults/main.yml: use contiv 1.1.7 Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
7 years ago
6 years ago
8 years ago
6 years ago
8 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
  1. stages:
  2. - unit-tests
  3. - moderator
  4. - deploy-part1
  5. - deploy-part2
  6. - deploy-special
  7. variables:
  8. FAILFASTCI_NAMESPACE: 'kargo-ci'
  9. GITLAB_REPOSITORY: 'kargo-ci/kubernetes-incubator__kubespray'
  10. # DOCKER_HOST: tcp://localhost:2375
  11. ANSIBLE_FORCE_COLOR: "true"
  12. MAGIC: "ci check this"
  13. TEST_ID: "$CI_PIPELINE_ID-$CI_BUILD_ID"
  14. CI_TEST_VARS: "./tests/files/${CI_JOB_NAME}.yml"
  15. GS_ACCESS_KEY_ID: $GS_KEY
  16. GS_SECRET_ACCESS_KEY: $GS_SECRET
  17. CONTAINER_ENGINE: docker
  18. SSH_USER: root
  19. GCE_PREEMPTIBLE: "false"
  20. ANSIBLE_KEEP_REMOTE_FILES: "1"
  21. ANSIBLE_CONFIG: ./tests/ansible.cfg
  22. IDEMPOT_CHECK: "false"
  23. RESET_CHECK: "false"
  24. UPGRADE_TEST: "false"
  25. KUBEADM_ENABLED: "false"
  26. LOG_LEVEL: "-vv"
  27. # asia-east1-a
  28. # asia-northeast1-a
  29. # europe-west1-b
  30. # us-central1-a
  31. # us-east1-b
  32. # us-west1-a
  33. before_script:
  34. - /usr/bin/python -m pip install -r tests/requirements.txt
  35. - mkdir -p /.ssh
  36. .job: &job
  37. tags:
  38. - kubernetes
  39. - docker
  40. image: quay.io/kubespray/kubespray:latest
  41. .docker_service: &docker_service
  42. services:
  43. - docker:dind
  44. .create_cluster: &create_cluster
  45. <<: *job
  46. <<: *docker_service
  47. .gce_variables: &gce_variables
  48. GCE_USER: travis
  49. SSH_USER: $GCE_USER
  50. CLOUD_MACHINE_TYPE: "g1-small"
  51. CI_PLATFORM: "gce"
  52. PRIVATE_KEY: $GCE_PRIVATE_KEY
  53. .do_variables: &do_variables
  54. PRIVATE_KEY: $DO_PRIVATE_KEY
  55. CI_PLATFORM: "do"
  56. SSH_USER: root
  57. .testcases: &testcases
  58. <<: *job
  59. <<: *docker_service
  60. cache:
  61. key: "$CI_BUILD_REF_NAME"
  62. paths:
  63. - downloads/
  64. - $HOME/.cache
  65. before_script:
  66. - docker info
  67. - /usr/bin/python -m pip install -r requirements.txt
  68. - /usr/bin/python -m pip install -r tests/requirements.txt
  69. - mkdir -p /.ssh
  70. - mkdir -p $HOME/.ssh
  71. - ansible-playbook --version
  72. - export PYPATH=$([[ ! "$CI_JOB_NAME" =~ "coreos" ]] && echo /usr/bin/python || echo /opt/bin/python)
  73. - echo "CI_JOB_NAME is $CI_JOB_NAME"
  74. - echo "PYPATH is $PYPATH"
  75. script:
  76. - pwd
  77. - ls
  78. - echo ${PWD}
  79. - echo "${STARTUP_SCRIPT}"
  80. - cd tests && make create-${CI_PLATFORM} -s ; cd -
  81. # Check out latest tag if testing upgrade
  82. # Uncomment when gitlab kargo repo has tags
  83. #- test "${UPGRADE_TEST}" != "false" && git fetch --all && git checkout $(git describe --tags $(git rev-list --tags --max-count=1))
  84. - test "${UPGRADE_TEST}" != "false" && git checkout ba0a03a8ba2d97a73d06242ec4bb3c7e2012e58c
  85. # Checkout the CI vars file so it is available
  86. - test "${UPGRADE_TEST}" != "false" && git checkout "${CI_BUILD_REF}" tests/files/${CI_JOB_NAME}.yml
  87. # Workaround https://github.com/kubernetes-incubator/kubespray/issues/2021
  88. - 'sh -c "echo ignore_assert_errors: true | tee -a tests/files/${CI_JOB_NAME}.yml"'
  89. # Create cluster
  90. - >
  91. ansible-playbook
  92. -i inventory/sample/hosts.ini
  93. -b --become-user=root
  94. --private-key=${HOME}/.ssh/id_rsa
  95. -u $SSH_USER
  96. ${SSH_ARGS}
  97. ${LOG_LEVEL}
  98. -e @${CI_TEST_VARS}
  99. -e ansible_ssh_user=${SSH_USER}
  100. -e local_release_dir=${PWD}/downloads
  101. --limit "all:!fake_hosts"
  102. cluster.yml
  103. # Repeat deployment if testing upgrade
  104. - >
  105. if [ "${UPGRADE_TEST}" != "false" ]; then
  106. test "${UPGRADE_TEST}" == "basic" && PLAYBOOK="cluster.yml";
  107. test "${UPGRADE_TEST}" == "graceful" && PLAYBOOK="upgrade-cluster.yml";
  108. git checkout "${CI_BUILD_REF}";
  109. ansible-playbook
  110. -i inventory/sample/hosts.ini
  111. -b --become-user=root
  112. --private-key=${HOME}/.ssh/id_rsa
  113. -u $SSH_USER
  114. ${SSH_ARGS}
  115. ${LOG_LEVEL}
  116. -e @${CI_TEST_VARS}
  117. -e ansible_ssh_user=${SSH_USER}
  118. -e local_release_dir=${PWD}/downloads
  119. --limit "all:!fake_hosts"
  120. $PLAYBOOK;
  121. fi
  122. # Tests Cases
  123. ## Test Master API
  124. - >
  125. ansible-playbook -i inventory/sample/hosts.ini -e ansible_python_interpreter=${PYPATH} -u $SSH_USER -e ansible_ssh_user=$SSH_USER $SSH_ARGS -b --become-user=root --limit "all:!fake_hosts" tests/testcases/010_check-apiserver.yml $LOG_LEVEL
  126. -e "{kubeadm_enabled: ${KUBEADM_ENABLED}}"
  127. ## Ping the between 2 pod
  128. - ansible-playbook -i inventory/sample/hosts.ini -e ansible_python_interpreter=${PYPATH} -u $SSH_USER -e ansible_ssh_user=$SSH_USER $SSH_ARGS -b --become-user=root --limit "all:!fake_hosts" tests/testcases/030_check-network.yml $LOG_LEVEL
  129. ## Advanced DNS checks
  130. - ansible-playbook -i inventory/sample/hosts.ini -e ansible_python_interpreter=${PYPATH} -u $SSH_USER -e ansible_ssh_user=$SSH_USER $SSH_ARGS -b --become-user=root --limit "all:!fake_hosts" tests/testcases/040_check-network-adv.yml $LOG_LEVEL
  131. ## Idempotency checks 1/5 (repeat deployment)
  132. - >
  133. if [ "${IDEMPOT_CHECK}" = "true" ]; then
  134. ansible-playbook
  135. -i inventory/sample/hosts.ini
  136. -b --become-user=root
  137. --private-key=${HOME}/.ssh/id_rsa
  138. -u $SSH_USER
  139. ${SSH_ARGS}
  140. ${LOG_LEVEL}
  141. -e @${CI_TEST_VARS}
  142. -e ansible_python_interpreter=${PYPATH}
  143. -e local_release_dir=${PWD}/downloads
  144. --limit "all:!fake_hosts"
  145. cluster.yml;
  146. fi
  147. ## Idempotency checks 2/5 (Advanced DNS checks)
  148. - >
  149. if [ "${IDEMPOT_CHECK}" = "true" ]; then
  150. ansible-playbook
  151. -i inventory/sample/hosts.ini
  152. -b --become-user=root
  153. --private-key=${HOME}/.ssh/id_rsa
  154. -u $SSH_USER
  155. ${SSH_ARGS}
  156. ${LOG_LEVEL}
  157. -e @${CI_TEST_VARS}
  158. --limit "all:!fake_hosts"
  159. tests/testcases/040_check-network-adv.yml $LOG_LEVEL;
  160. fi
  161. ## Idempotency checks 3/5 (reset deployment)
  162. - >
  163. if [ "${IDEMPOT_CHECK}" = "true" -a "${RESET_CHECK}" = "true" ]; then
  164. ansible-playbook
  165. -i inventory/sample/hosts.ini
  166. -b --become-user=root
  167. --private-key=${HOME}/.ssh/id_rsa
  168. -u $SSH_USER
  169. ${SSH_ARGS}
  170. ${LOG_LEVEL}
  171. -e @${CI_TEST_VARS}
  172. -e ansible_python_interpreter=${PYPATH}
  173. -e reset_confirmation=yes
  174. --limit "all:!fake_hosts"
  175. reset.yml;
  176. fi
  177. ## Idempotency checks 4/5 (redeploy after reset)
  178. - >
  179. if [ "${IDEMPOT_CHECK}" = "true" -a "${RESET_CHECK}" = "true" ]; then
  180. ansible-playbook
  181. -i inventory/sample/hosts.ini
  182. -b --become-user=root
  183. --private-key=${HOME}/.ssh/id_rsa
  184. -u $SSH_USER
  185. ${SSH_ARGS}
  186. ${LOG_LEVEL}
  187. -e @${CI_TEST_VARS}
  188. -e ansible_python_interpreter=${PYPATH}
  189. -e local_release_dir=${PWD}/downloads
  190. --limit "all:!fake_hosts"
  191. cluster.yml;
  192. fi
  193. ## Idempotency checks 5/5 (Advanced DNS checks)
  194. - >
  195. if [ "${IDEMPOT_CHECK}" = "true" -a "${RESET_CHECK}" = "true" ]; then
  196. ansible-playbook -i inventory/sample/hosts.ini -e ansible_python_interpreter=${PYPATH}
  197. -u $SSH_USER -e ansible_ssh_user=$SSH_USER $SSH_ARGS -b --become-user=root
  198. --limit "all:!fake_hosts"
  199. tests/testcases/040_check-network-adv.yml $LOG_LEVEL;
  200. fi
  201. after_script:
  202. - cd tests && make delete-${CI_PLATFORM} -s ; cd -
  203. .gce: &gce
  204. <<: *testcases
  205. variables:
  206. <<: *gce_variables
  207. .do: &do
  208. variables:
  209. <<: *do_variables
  210. <<: *testcases
  211. # Test matrix. Leave the comments for markup scripts.
  212. .coreos_calico_aio_variables: &coreos_calico_aio_variables
  213. # stage: deploy-part1
  214. MOVED_TO_GROUP_VARS: "true"
  215. .ubuntu_canal_ha_variables: &ubuntu_canal_ha_variables
  216. # stage: deploy-part1
  217. UPGRADE_TEST: "graceful"
  218. .centos_weave_kubeadm_variables: &centos_weave_kubeadm_variables
  219. # stage: deploy-part1
  220. UPGRADE_TEST: "graceful"
  221. .ubuntu_canal_kubeadm_variables: &ubuntu_canal_kubeadm_variables
  222. # stage: deploy-part1
  223. MOVED_TO_GROUP_VARS: "true"
  224. .ubuntu_contiv_sep_variables: &ubuntu_contiv_sep_variables
  225. # stage: deploy-special
  226. MOVED_TO_GROUP_VARS: "true"
  227. .coreos_cilium_variables: &coreos_cilium_variables
  228. # stage: deploy-special
  229. MOVED_TO_GROUP_VARS: "true"
  230. .ubuntu_cilium_sep_variables: &ubuntu_cilium_sep_variables
  231. # stage: deploy-special
  232. MOVED_TO_GROUP_VARS: "true"
  233. .rhel7_weave_variables: &rhel7_weave_variables
  234. # stage: deploy-part1
  235. MOVED_TO_GROUP_VARS: "true"
  236. .centos7_flannel_addons_variables: &centos7_flannel_addons_variables
  237. # stage: deploy-part2
  238. MOVED_TO_GROUP_VARS: "true"
  239. .debian8_calico_variables: &debian8_calico_variables
  240. # stage: deploy-part2
  241. MOVED_TO_GROUP_VARS: "true"
  242. .coreos_canal_variables: &coreos_canal_variables
  243. # stage: deploy-part2
  244. MOVED_TO_GROUP_VARS: "true"
  245. .rhel7_canal_sep_variables: &rhel7_canal_sep_variables
  246. # stage: deploy-special
  247. MOVED_TO_GROUP_VARS: "true"
  248. .ubuntu_weave_sep_variables: &ubuntu_weave_sep_variables
  249. # stage: deploy-special
  250. MOVED_TO_GROUP_VARS: "true"
  251. .centos7_calico_ha_variables: &centos7_calico_ha_variables
  252. # stage: deploy-special
  253. MOVED_TO_GROUP_VARS: "true"
  254. .coreos_alpha_weave_ha_variables: &coreos_alpha_weave_ha_variables
  255. # stage: deploy-special
  256. MOVED_TO_GROUP_VARS: "true"
  257. .ubuntu_rkt_sep_variables: &ubuntu_rkt_sep_variables
  258. # stage: deploy-part1
  259. MOVED_TO_GROUP_VARS: "true"
  260. .ubuntu_vault_sep_variables: &ubuntu_vault_sep_variables
  261. # stage: deploy-part1
  262. MOVED_TO_GROUP_VARS: "true"
  263. .ubuntu_flannel_variables: &ubuntu_flannel_variables
  264. # stage: deploy-special
  265. MOVED_TO_GROUP_VARS: "true"
  266. # Builds for PRs only (premoderated by unit-tests step) and triggers (auto)
  267. ### PR JOBS PART1
  268. gce_coreos-calico-aio:
  269. stage: deploy-part1
  270. <<: *job
  271. <<: *gce
  272. variables:
  273. <<: *coreos_calico_aio_variables
  274. <<: *gce_variables
  275. when: on_success
  276. except: ['triggers']
  277. only: [/^pr-.*$/]
  278. ### PR JOBS PART2
  279. gce_centos7-flannel-addons:
  280. stage: deploy-part2
  281. <<: *job
  282. <<: *gce
  283. variables:
  284. <<: *gce_variables
  285. <<: *centos7_flannel_addons_variables
  286. when: on_success
  287. except: ['triggers']
  288. only: [/^pr-.*$/]
  289. gce_ubuntu-weave-sep:
  290. stage: deploy-part2
  291. <<: *job
  292. <<: *gce
  293. variables:
  294. <<: *gce_variables
  295. <<: *ubuntu_weave_sep_variables
  296. when: on_success
  297. except: ['triggers']
  298. only: [/^pr-.*$/]
  299. ### MANUAL JOBS
  300. gce_coreos-calico-sep-triggers:
  301. stage: deploy-part2
  302. <<: *job
  303. <<: *gce
  304. variables:
  305. <<: *gce_variables
  306. <<: *coreos_calico_aio_variables
  307. when: on_success
  308. only: ['triggers']
  309. gce_ubuntu-canal-ha-triggers:
  310. stage: deploy-part2
  311. <<: *job
  312. <<: *gce
  313. variables:
  314. <<: *gce_variables
  315. <<: *ubuntu_canal_ha_variables
  316. when: on_success
  317. only: ['triggers']
  318. gce_centos7-flannel-addons-triggers:
  319. stage: deploy-part2
  320. <<: *job
  321. <<: *gce
  322. variables:
  323. <<: *gce_variables
  324. <<: *centos7_flannel_addons_variables
  325. when: on_success
  326. only: ['triggers']
  327. gce_ubuntu-weave-sep-triggers:
  328. stage: deploy-part2
  329. <<: *job
  330. <<: *gce
  331. variables:
  332. <<: *gce_variables
  333. <<: *ubuntu_weave_sep_variables
  334. when: on_success
  335. only: ['triggers']
  336. # More builds for PRs/merges (manual) and triggers (auto)
  337. do_ubuntu-canal-ha:
  338. stage: deploy-part2
  339. <<: *job
  340. <<: *do
  341. variables:
  342. <<: *do_variables
  343. when: manual
  344. except: ['triggers']
  345. only: ['master', /^pr-.*$/]
  346. gce_ubuntu-canal-ha:
  347. stage: deploy-part2
  348. <<: *job
  349. <<: *gce
  350. variables:
  351. <<: *gce_variables
  352. <<: *ubuntu_canal_ha_variables
  353. when: manual
  354. except: ['triggers']
  355. only: ['master', /^pr-.*$/]
  356. gce_ubuntu-canal-kubeadm:
  357. stage: deploy-part2
  358. <<: *job
  359. <<: *gce
  360. variables:
  361. <<: *gce_variables
  362. <<: *ubuntu_canal_kubeadm_variables
  363. when: manual
  364. except: ['triggers']
  365. only: ['master', /^pr-.*$/]
  366. gce_ubuntu-canal-kubeadm-triggers:
  367. stage: deploy-part2
  368. <<: *job
  369. <<: *gce
  370. variables:
  371. <<: *gce_variables
  372. <<: *ubuntu_canal_kubeadm_variables
  373. when: on_success
  374. only: ['triggers']
  375. gce_centos-weave-kubeadm:
  376. stage: deploy-part2
  377. <<: *job
  378. <<: *gce
  379. variables:
  380. <<: *gce_variables
  381. <<: *centos_weave_kubeadm_variables
  382. when: manual
  383. except: ['triggers']
  384. only: ['master', /^pr-.*$/]
  385. gce_centos-weave-kubeadm-triggers:
  386. stage: deploy-part2
  387. <<: *job
  388. <<: *gce
  389. variables:
  390. <<: *gce_variables
  391. <<: *centos_weave_kubeadm_variables
  392. when: on_success
  393. only: ['triggers']
  394. gce_ubuntu-contiv-sep:
  395. stage: deploy-special
  396. <<: *job
  397. <<: *gce
  398. variables:
  399. <<: *gce_variables
  400. <<: *ubuntu_contiv_sep_variables
  401. when: manual
  402. except: ['triggers']
  403. only: ['master', /^pr-.*$/]
  404. gce_coreos-cilium:
  405. stage: deploy-special
  406. <<: *job
  407. <<: *gce
  408. variables:
  409. <<: *gce_variables
  410. <<: *coreos_cilium_variables
  411. when: manual
  412. except: ['triggers']
  413. only: ['master', /^pr-.*$/]
  414. gce_ubuntu-cilium-sep:
  415. stage: deploy-special
  416. <<: *job
  417. <<: *gce
  418. variables:
  419. <<: *gce_variables
  420. <<: *ubuntu_cilium_sep_variables
  421. when: manual
  422. except: ['triggers']
  423. only: ['master', /^pr-.*$/]
  424. gce_rhel7-weave:
  425. stage: deploy-part2
  426. <<: *job
  427. <<: *gce
  428. variables:
  429. <<: *gce_variables
  430. <<: *rhel7_weave_variables
  431. when: manual
  432. except: ['triggers']
  433. only: ['master', /^pr-.*$/]
  434. gce_rhel7-weave-triggers:
  435. stage: deploy-part2
  436. <<: *job
  437. <<: *gce
  438. variables:
  439. <<: *gce_variables
  440. <<: *rhel7_weave_variables
  441. when: on_success
  442. only: ['triggers']
  443. gce_debian8-calico-upgrade:
  444. stage: deploy-part2
  445. <<: *job
  446. <<: *gce
  447. variables:
  448. <<: *gce_variables
  449. <<: *debian8_calico_variables
  450. when: manual
  451. except: ['triggers']
  452. only: ['master', /^pr-.*$/]
  453. gce_debian8-calico-triggers:
  454. stage: deploy-part2
  455. <<: *job
  456. <<: *gce
  457. variables:
  458. <<: *gce_variables
  459. <<: *debian8_calico_variables
  460. when: on_success
  461. only: ['triggers']
  462. gce_coreos-canal:
  463. stage: deploy-part2
  464. <<: *job
  465. <<: *gce
  466. variables:
  467. <<: *gce_variables
  468. <<: *coreos_canal_variables
  469. when: manual
  470. except: ['triggers']
  471. only: ['master', /^pr-.*$/]
  472. gce_coreos-canal-triggers:
  473. stage: deploy-part2
  474. <<: *job
  475. <<: *gce
  476. variables:
  477. <<: *gce_variables
  478. <<: *coreos_canal_variables
  479. when: on_success
  480. only: ['triggers']
  481. gce_rhel7-canal-sep:
  482. stage: deploy-special
  483. <<: *job
  484. <<: *gce
  485. variables:
  486. <<: *gce_variables
  487. <<: *rhel7_canal_sep_variables
  488. when: manual
  489. except: ['triggers']
  490. only: ['master', /^pr-.*$/,]
  491. gce_rhel7-canal-sep-triggers:
  492. stage: deploy-part2
  493. <<: *job
  494. <<: *gce
  495. variables:
  496. <<: *gce_variables
  497. <<: *rhel7_canal_sep_variables
  498. when: on_success
  499. only: ['triggers']
  500. gce_centos7-calico-ha:
  501. stage: deploy-special
  502. <<: *job
  503. <<: *gce
  504. variables:
  505. <<: *gce_variables
  506. <<: *centos7_calico_ha_variables
  507. when: manual
  508. except: ['triggers']
  509. only: ['master', /^pr-.*$/]
  510. gce_centos7-calico-ha-triggers:
  511. stage: deploy-part2
  512. <<: *job
  513. <<: *gce
  514. variables:
  515. <<: *gce_variables
  516. <<: *centos7_calico_ha_variables
  517. when: on_success
  518. only: ['triggers']
  519. # no triggers yet https://github.com/kubernetes-incubator/kargo/issues/613
  520. gce_coreos-alpha-weave-ha:
  521. stage: deploy-special
  522. <<: *job
  523. <<: *gce
  524. variables:
  525. <<: *gce_variables
  526. <<: *coreos_alpha_weave_ha_variables
  527. when: manual
  528. except: ['triggers']
  529. only: ['master', /^pr-.*$/]
  530. gce_ubuntu-rkt-sep:
  531. stage: deploy-part2
  532. <<: *job
  533. <<: *gce
  534. variables:
  535. <<: *gce_variables
  536. <<: *ubuntu_rkt_sep_variables
  537. when: manual
  538. except: ['triggers']
  539. only: ['master', /^pr-.*$/]
  540. gce_ubuntu-vault-sep:
  541. stage: deploy-part2
  542. <<: *job
  543. <<: *gce
  544. variables:
  545. <<: *gce_variables
  546. <<: *ubuntu_vault_sep_variables
  547. when: manual
  548. except: ['triggers']
  549. only: ['master', /^pr-.*$/]
  550. gce_ubuntu-flannel-sep:
  551. stage: deploy-special
  552. <<: *job
  553. <<: *gce
  554. variables:
  555. <<: *gce_variables
  556. <<: *ubuntu_flannel_variables
  557. when: manual
  558. except: ['triggers']
  559. only: ['master', /^pr-.*$/]
  560. # Premoderated with manual actions
  561. ci-authorized:
  562. <<: *job
  563. stage: moderator
  564. before_script:
  565. - apt-get -y install jq
  566. script:
  567. - /bin/sh scripts/premoderator.sh
  568. except: ['triggers', 'master']
  569. syntax-check:
  570. <<: *job
  571. stage: unit-tests
  572. script:
  573. - ansible-playbook -i inventory/local-tests.cfg -u root -e ansible_ssh_user=root -b --become-user=root cluster.yml -vvv --syntax-check
  574. - ansible-playbook -i inventory/local-tests.cfg -u root -e ansible_ssh_user=root -b --become-user=root upgrade-cluster.yml -vvv --syntax-check
  575. - ansible-playbook -i inventory/local-tests.cfg -u root -e ansible_ssh_user=root -b --become-user=root reset.yml -vvv --syntax-check
  576. - ansible-playbook -i inventory/local-tests.cfg -u root -e ansible_ssh_user=root -b --become-user=root extra_playbooks/upgrade-only-k8s.yml -vvv --syntax-check
  577. except: ['triggers', 'master']
  578. yamllint:
  579. <<: *job
  580. stage: unit-tests
  581. script:
  582. - yamllint roles
  583. except: ['triggers', 'master']
  584. tox-inventory-builder:
  585. stage: unit-tests
  586. <<: *job
  587. script:
  588. - pip install tox
  589. - cd contrib/inventory_builder && tox
  590. when: manual
  591. except: ['triggers', 'master']