Przeglądaj źródła

added ci inventory and groups for containerized

Michael Gugino 7 lat temu
rodzic
commit
e882e552a9

+ 1 - 0
roles/openshift_health_checker/openshift_checks/docker_image_availability.py

@@ -149,6 +149,7 @@ class DockerImageAvailability(DockerHostMixin, OpenShiftCheck):
         host_groups = self.get_var("group_names")
         # containerized etcd may not have openshift_image_tag, see bz 1466622
         image_tag = self.get_var("openshift_image_tag", default="latest")
+        image_tag = self.template_var(image_tag)
         image_info = DEPLOYMENT_IMAGE_INFO[deployment_type]
 
         # template for images that run on top of OpenShift

+ 2 - 3
test/ci/install.sh

@@ -15,15 +15,14 @@ ansible-playbook -vv            \
 
 echo "Running network_manager setup"
 
-playbook_base='/usr/share/ansible/openshift-ansible/playbooks/'
 if [[ -s "$1/openshift-node/network_manager.yml" ]]; then
    playbook="$1/openshift-node/network_manager.yml"
 else
    playbook="$1/byo/openshift-node/network_manager.yml"
 fi
 ansible-playbook -vv            \
-                 --inventory $1 \
-                 --e @$2        \
+                 --inventory $2 \
+                 --e @$3       \
                 ${playbook}
 
 echo "Running openshift-ansible deploy_cluster"

+ 0 - 21
test/ci/inventory/group_vars/OSEv3/general.yml

@@ -1,23 +1,2 @@
 ---
 debug_level: 5
-osm_default_node_selector: "region=infra"
-osm_controller_args:
-  enable-hostpath-provisioner:
-    - "true"
-openshift_hosted_router_selector: "region=infra"
-openshift_hosted_router_create_certificate: true
-openshift_hosted_registry_selector: "region=infra"
-openshift_master_audit_config:
-  enabled: true
-openshift_master_identity_providers:
-  - name: "allow_all"
-    login: "true"
-    challenge: "true"
-    kind: "AllowAllPasswordIdentityProvider"
-openshift_template_service_broker_namespaces:
-  - "openshift"
-ansible_ssh_user: "ec2-user"
-enable_excluders: "false"
-osm_cluster_network_cidr: "10.128.0.0/14"
-openshift_portal_net: "172.30.0.0/16"
-osm_host_subnet_length: 9

+ 28 - 5
test/ci/inventory/group_vars/all.yml

@@ -1,13 +1,36 @@
 ---
+# The variables in this file may be overridden by different group vars.
+# The 'all' group is overridden by any specific group that a host is a part of,
+# and the values here serve as 'defaults' for the CI testing.
+
 openshift_deployment_type: origin
-etcd_data_dir: "${ETCD_DATA_DIR}"
+etcd_data_dir: "{{ lookup('env', 'ETCD_DATA_DIR') | default('/var/lib/etcd/') }}"
 openshift_node_port_range: '30000-32000'
-osm_controller_args:
-  enable-hostpath-provisioner:
-    - "true"
 
 # These env vars are created by the CI.  This allows us
 # to test specific versions of openshift.
-openshift_pkg_version: "{{ lookup('env', 'ORIGIN_PKG_VERSION') }}"
+openshift_pkg_version: "{{ lookup('env', 'ORIGIN_TAG') }}"
 openshift_release: "{{ lookup('env', 'ORIGIN_RELEASE') }}"
 oreg_url: "openshift/origin-${component}:{{ lookup('env', 'ORIGIN_COMMIT') }}"
+
+osm_default_node_selector: "region=infra"
+osm_controller_args:
+  enable-hostpath-provisioner:
+    - "true"
+openshift_hosted_router_selector: "region=infra"
+openshift_hosted_router_create_certificate: true
+openshift_hosted_registry_selector: "region=infra"
+openshift_master_audit_config:
+  enabled: true
+openshift_master_identity_providers:
+  - name: "allow_all"
+    login: "true"
+    challenge: "true"
+    kind: "AllowAllPasswordIdentityProvider"
+openshift_template_service_broker_namespaces:
+  - "openshift"
+ansible_ssh_user: "ec2-user"
+enable_excluders: "false"
+osm_cluster_network_cidr: "10.128.0.0/14"
+openshift_portal_net: "172.30.0.0/16"
+osm_host_subnet_length: 9

+ 4 - 0
test/ci/inventory/group_vars/containerized_hosts.yml

@@ -0,0 +1,4 @@
+---
+openshift_image_tag: "{{ lookup('env', 'OPENSHIFT_IMAGE_TAG') }}"
+oreg_url: "openshift/origin-${component}:{{ openshift_image_tag }}"
+containerized: True

+ 30 - 0
test/ci/inventory/local_containerized.txt

@@ -0,0 +1,30 @@
+[containerized_hosts]
+
+[containerized_hosts:children]
+masters
+nodes
+etcd
+
+[OSEv3]
+
+[OSEv3:children]
+masters
+nodes
+etcd
+lb
+nfs
+
+[lb]
+# Empty, but present to pass integration tests.
+
+[nfs]
+# Empty, but present to pass integration tests.
+
+[masters]
+localhost
+
+[nodes]
+localhost
+
+[etcd]
+localhost