1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768 |
- ---
- - name: Enable bootstrapping in the master config
- yedit:
- src: /etc/origin/master/master-config.yaml
- edits:
- - key: kubernetesMasterConfig.controllerArguments.cluster-signing-cert-file
- value:
- - /etc/origin/master/ca.crt
- - key: kubernetesMasterConfig.controllerArguments.cluster-signing-key-file
- value:
- - /etc/origin/master/ca.key
- - name: Create temp directory for static pods
- command: mktemp -d /tmp/openshift-ansible-XXXXXX
- register: mktemp
- changed_when: false
- - name: Prepare master static pods
- copy:
- src: "{{ item }}"
- dest: "{{ mktemp.stdout }}"
- mode: 0600
- with_items:
- - apiserver.yaml
- - controller.yaml
- - name: Update master static pods
- yedit:
- src: "{{ mktemp.stdout }}/{{ item }}"
- edits:
- - key: spec.containers[0].image
- value: "{{ osm_image }}"
- with_items:
- - apiserver.yaml
- - controller.yaml
- - name: Update master static pod (api)
- yedit:
- src: "{{ mktemp.stdout }}/apiserver.yaml"
- edits:
- - key: spec.containers[0].livenessProbe.httpGet.port
- value: "{{ openshift_master_api_port }}"
- - key: spec.containers[0].readinessProbe.httpGet.port
- value: "{{ openshift_master_api_port }}"
- - name: Update master static pods
- copy:
- remote_src: true
- src: "{{ mktemp.stdout }}/{{ item }}"
- dest: "/etc/origin/node/pods/"
- mode: 0600
- with_items:
- - apiserver.yaml
- - controller.yaml
- - name: Remove old files in /etc/sysconfig
- file:
- name: "{{ item }}"
- state: absent
- with_items:
- - /etc/sysconfig/{{ openshift_service_type }}-master-api
- - /etc/sysconfig/{{ openshift_service_type }}-master-controllers
- - name: Remove temporary directory
- file:
- name: "{{ mktemp.stdout }}"
- state: absent
- changed_when: False
|