Ver código fonte

Changes for new Nuage RPMS

Vishal Patil 9 anos atrás
pai
commit
3535ab6d8d

+ 2 - 2
roles/nuage_master/handlers/main.yaml

@@ -1,7 +1,7 @@
 ---
-- name: restart nuagekubemon
+- name: restart nuage-openshift-monitor
   sudo: true
-  service: name=nuagekubemon state=restarted
+  service: name=nuage-openshift-monitor state=restarted
 
 - name: restart master
   service: name={{ openshift.common.service_type }}-master state=restarted

+ 8 - 8
roles/nuage_master/tasks/main.yaml

@@ -1,15 +1,15 @@
 ---
-- name: Create directory /usr/share/nuagekubemon
+- name: Create directory /usr/share/nuage-openshift-monitor
   sudo: true
-  file: path=/usr/share/nuagekubemon state=directory  
+  file: path=/usr/share/nuage-openshift-monitor state=directory  
 
 - name: Create the log directory
   sudo: true
-  file: path={{ nuagekubemon_log_dir }} state=directory
+  file: path={{ nuage_openshift_monitor_log_dir }} state=directory
 
-- name: Install Nuage Kubemon
+- name: Install Nuage Openshift Monitor 
   sudo: true
-  yum: name={{ nuage_kubemon_rpm }} state=present
+  yum: name={{ nuage_openshift_rpm }} state=present
 
 - name: Run the service account creation script
   sudo: true
@@ -24,11 +24,11 @@
         - nuage.key
         - nuage.kubeconfig 
  
-- name: Create nuagekubemon.yaml
+- name: Create nuage-openshift-monitor.yaml
   sudo: true
-  template: src=nuagekubemon.j2 dest=/usr/share/nuagekubemon/nuagekubemon.yaml owner=root mode=0644
+  template: src=nuage-openshift-monitor.j2 dest=/usr/share/nuage-openshift-monitor/nuage-openshift-monitor.yaml owner=root mode=0644
   notify:
     - restart master
     - restart master api
     - restart master controllers
-    - restart nuagekubemon
+    - restart nuage-openshift-monitor

+ 2 - 2
roles/nuage_master/templates/nuagekubemon.j2

@@ -3,7 +3,7 @@ kubeConfig: {{ kube_config }}
 # name of the nuage service account, or another account with 'cluster-reader'
 # permissions
 # Openshift master config file
-openshiftMasterConfig: {{ master_config_yaml }} 
+masterConfig: {{ master_config_yaml }} 
 # URL of the VSD Architect
 vsdApiUrl: {{ vsd_api_url }} 
 # API version to query against.  Usually "v3_2"
@@ -16,4 +16,4 @@ enterpriseName: {{ enterprise }}
 # Name of the domain in which pods will reside
 domainName: {{ domain }}
 # Location where logs should be saved
-log_dir: {{ nuagekubemon_log_dir }} 
+log_dir: {{ nuage_openshift_monitor_log_dir }} 

+ 3 - 3
roles/nuage_master/vars/main.yaml

@@ -1,7 +1,7 @@
 openshift_master_config_dir: "{{ openshift.common.config_base }}/master"
 ca_cert: "{{ openshift_master_config_dir }}/ca.crt"
 admin_config: "{{ openshift.common.config_base }}/master/admin.kubeconfig"
-cert_output_dir: /usr/share/nuagekubemon
-kube_config: /usr/share/nuagekubemon/nuage.kubeconfig
-kubemon_yaml: /usr/share/nuagekubemon/nuagekubemon.yaml 
+cert_output_dir: /usr/share/nuage-openshift-monitor
+kube_config: /usr/share/nuage-openshift-monitor/nuage.kubeconfig
+kubemon_yaml: /usr/share/nuage-openshift-monitor/nuage-openshift-monitor.yaml 
 master_config_yaml: "{{ openshift_master_config_dir }}/master-config.yaml" 

+ 3 - 3
roles/nuage_node/tasks/main.yaml

@@ -22,16 +22,16 @@
 
 - name: Copy the certificates and keys
   sudo: true
-  copy: src="/tmp/{{ item }}" dest="{{ vsp_k8s_dir }}/{{ item }}"
+  copy: src="/tmp/{{ item }}" dest="{{ vsp_openshift_dir }}/{{ item }}"
   with_items:
         - ca.crt
         - nuage.crt
         - nuage.key
         - nuage.kubeconfig 
 
-- name: Set the vsp-k8s.yaml 
+- name: Set the vsp-openshift.yaml 
   sudo: true
-  template: src=vsp-k8s.j2 dest={{ vsp_k8s_yaml }} owner=root mode=0644 
+  template: src=vsp-openshift.j2 dest={{ vsp_openshift_yaml }} owner=root mode=0644 
   notify:
     - restart vrs
     - restart node 

roles/nuage_node/templates/vsp-k8s.j2 → roles/nuage_node/templates/vsp-openshift.j2


+ 5 - 5
roles/nuage_node/vars/main.yaml

@@ -1,9 +1,9 @@
 ---
 vrs_config: /etc/default/openvswitch
-vsp_k8s_dir: /usr/share/vsp-k8s
-vsp_k8s_yaml: "{{ vsp_k8s_dir }}/vsp-k8s.yaml"
-client_cert: "{{ vsp_k8s_dir }}/nuage.crt"
-client_key: "{{ vsp_k8s_dir }}/nuage.key"
-ca_cert: "{{ vsp_k8s_dir }}/ca.crt"
+vsp_openshift_dir: /usr/share/vsp-openshift
+vsp_openshift_yaml: "{{ vsp_openshift_dir }}/vsp-openshift.yaml"
+client_cert: "{{ vsp_openshift_dir }}/nuage.crt"
+client_key: "{{ vsp_openshift_dir }}/nuage.key"
+ca_cert: "{{ vsp_openshift_dir }}/ca.crt"
 api_server: "{{ openshift_node_master_api_url }}"
 docker_bridge: "docker0"