0
シンプルなアナーシブプレイブックを実行しようとしていますが、引き続き次のエラーが発生しています。以下はレジスタはアシアブルプレイの法的パラメータではありません
ERROR: register is not a legal parameter of an Ansible Play
私はあなたの全体の脚本だ
---
- name: Get SELinux sestatus
command: sestatus | grep enforcing | grep 'config file'
register: sestatus
- name: Check if module1.pp exists
stat:
path: bin/module1.pp
register: module1_pp
- name: Disable SELinux if enforcing
sudo: yes
command: "{{ item }}"
with_items:
- setenforce 0
- semodule -i bin/module1.pp
- setsebool -P httpd_can_network_connect 1
when: sestatus.rc == 0 and module1.stat.exists == true
助けてくれてありがとう、これは私の問題を修正 – bc81