Make vagrant CI normal (#6074)

This commit is contained in:
Maxime Guyot
2020-05-28 09:46:02 +02:00
committed by GitHub
parent 1be15a0864
commit 83d945127f
9 changed files with 34 additions and 10 deletions

View File

@@ -72,3 +72,11 @@ delete-packet:
-e @"files/${CI_JOB_NAME}.yml" \
-e test_id=$(TEST_ID) \
-e inventory_path=$(INVENTORY)
create-vagrant:
vagrant up
find / -name vagrant_ansible_inventory
cp /builds/kargo-ci/kubernetes-sigs-kubespray/inventory/sample/vagrant_ansible_inventory $(INVENTORY)
delete-vagrant:
vagrant destroy -f

View File

@@ -3,4 +3,5 @@ $libvirt_volume_cache = "unsafe"
# Checking for box update can trigger API rate limiting
# https://www.vagrantup.com/docs/vagrant-cloud/request-limits.html
$box_check_update = false
$box_check_update = false
$vm_cpus = 2

View File

@@ -0,0 +1,7 @@
---
# Kubespray settings
kube_network_plugin: flannel
deploy_netchecker: true
dns_min_replicas: 1

View File

@@ -4,3 +4,4 @@ $os = "ubuntu1804"
$network_plugin = "weave"
$kube_master_instances = 1
$etcd_instances = 1
$playbook = "tests/cloud_playbooks/wait-for-ssh.yml"

View File

@@ -0,0 +1,7 @@
---
# Kubespray settings
kube_network_plugin: weave
deploy_netchecker: true
dns_min_replicas: 1

View File

@@ -188,7 +188,7 @@
EOF
when:
- inventory_hostname == groups['kube-master'][0]
- kube_network_plugin_multus|default(false)
- kube_network_plugin_multus|bool|default(false)
- name: Annotate pod with macvlan network
# We cannot use only shell: below because Ansible will render the text
@@ -212,7 +212,7 @@
EOF
when:
- inventory_hostname == groups['kube-master'][0]
- kube_network_plugin_multus|default(false)
- kube_network_plugin_multus|bool|default(false)
- name: Check secondary macvlan interface
shell: "{{ bin_dir }}/kubectl exec samplepod -- ip addr show dev net1"
@@ -222,4 +222,4 @@
changed_when: false
when:
- inventory_hostname == groups['kube-master'][0]
- kube_network_plugin_multus|default(false)
- kube_network_plugin_multus|bool|default(false)