--- - name: Create temporary directory for s390x artifacts ansible.builtin.tempfile: state: directory suffix: s390x register: temp_dir - name: Extract s390x release tools ansible.builtin.command: cmd: "oc adm release extract --tools quay.io/openshift-release-dev/ocp-release:{{ ocp_version }}-s390x" chdir: "{{ temp_dir.path }}" - name: Install coreos-installer ansible.builtin.package: name: coreos-installer state: present become: true when: ansible_os_family == "RedHat" - name: Install coreos-installer on Debian/Ubuntu block: - name: Add Rust repository ansible.builtin.apt_repository: repo: ppa:rust-lang/rust state: present - name: Install Rust and Cargo ansible.builtin.apt: name: - rust - cargo state: present update_cache: true - name: Install coreos-installer from cargo ansible.builtin.command: cmd: cargo install coreos-installer creates: ~/.cargo/bin/coreos-installer when: ansible_os_family == "Debian" become: true - name: Get cluster infrastructure details kubernetes.core.k8s_info: api_version: config.openshift.io/v1 kind: Infrastructure name: cluster register: cluster_infrastructure - name: Generate worker ignition config ansible.builtin.command: cmd: "openshift-install create worker-ignition" chdir: "{{ temp_dir.path }}" - name: Create ISO for s390x nodes ansible.builtin.command: cmd: >- coreos-installer iso customize --dest-ignition {{ temp_dir.path }}/worker.ign --output {{ temp_dir.path }}/s390x-worker.iso {{ temp_dir.path }}/rhcos-live.s390x.iso - name: Configure LPAR using HMC zhmc_lpar: hmc_host: "{{ hmc_host }}" hmc_auth: userid: "{{ hmc_auth.username }}" password: "{{ hmc_auth.password }}" cpc_name: "{{ cpc_name }}" name: "{{ inventory_hostname }}" state: inactive # First ensure LPAR is inactive properties: initial_memory: "{{ memory_mb }}" initial_processing_weight: "{{ cpu_count }}" - name: Mount ISO and activate LPAR zhmc_lpar_command: hmc_host: "{{ hmc_host }}" hmc_auth: userid: "{{ hmc_auth.username }}" password: "{{ hmc_auth.password }}" cpc_name: "{{ cpc_name }}" name: "{{ inventory_hostname }}" command: "mount {{ temp_dir.path }}/s390x-worker.iso" - name: Activate LPAR zhmc_lpar: hmc_host: "{{ hmc_host }}" hmc_auth: userid: "{{ hmc_auth.username }}" password: "{{ hmc_auth.password }}" cpc_name: "{{ cpc_name }}" name: "{{ inventory_hostname }}" state: active activation_profile_name: "{{ inventory_hostname }}" - name: Wait for node to join cluster kubernetes.core.k8s_info: api_version: v1 kind: Node name: "{{ inventory_hostname }}" register: node_status until: node_status.resources | length > 0 retries: 60 delay: 30