瀏覽代碼

better code

master
父節點
當前提交
6ebaeeee95
共有 1 個檔案被更改,包括 11 行新增6 行删除
  1. +11
    -6
      tasks/main.yml

+ 11
- 6
tasks/main.yml 查看文件

@@ -1,14 +1,18 @@
---

- name: Check if i386 is enabled
shell: dpkg --print-foreign-architectures | grep i386
- name: check if i386 is enabled
command: dpkg --print-foreign-architectures
register: result_i386_check
changed_when: result_i386_check.rc == 1
failed_when: result_i386_check.rc > 1
changed_when: not "i386" in result_i386_check.stdout_lines

- name: Enable i386 architecture
- name: enable i386 architecture
command: dpkg --add-architecture i386
when: result_i386_check.rc == 1
when: result_i386_check.changed

- name: update apt cache after enabling i386
apt:
update_cache: yes
when: result_i386_check.changed

- name: install multiarch libraries
apt:
@@ -17,4 +21,5 @@
- lib32stdc++6
- lib32z1
- lib32gcc1
- libc6:i386
when: ansible_architecture == "x86_64"

Loading…
取消
儲存