차이

문서의 선택한 두 판 사이의 차이를 보여줍니다.

차이 보기로 링크

양쪽 이전 판 이전 판
다음 판
이전 판
ansible_summary [2018/09/05 02:22] – [Filters] koovansible_summary [2018/10/04 02:25] (현재) koov
줄 239: 줄 239:
 ===== Lookups ===== ===== Lookups =====
  
-  * {{ lookup('file', '/etc/foo.txt') }} +  * <nowiki>{{ lookup('file', '/etc/foo.txt') }}</nowiki> 
-  * {{ lookup('password', '/tmp/passwordfile chars=ascii') }} +  * <nowiki>{{ lookup('password', '/tmp/passwordfile chars=ascii') }}</nowiki> 
-  * {{ lookup('env','HOME') }} +  * <nowiki>{{ lookup('env','HOME') }}</nowiki> 
-  * {{ lookup('pipe','date') }} +  * <nowiki>{{ lookup('pipe','date') }}</nowiki> 
-  * {{ lookup('redis_kv', 'redis://localhost:6379,somekey') }} +  * <nowiki>{{ lookup('redis_kv', 'redis://localhost:6379,somekey') }}</nowiki> 
-  * {{ lookup('dnstxt', 'example.com') }} +  * <nowiki>{{ lookup('dnstxt', 'example.com') }}</nowiki> 
-  * {{ lookup('template', './some_template.j2') }}+  * <nowiki>{{ lookup('template', './some_template.j2') }}</nowiki>
  
 ===== Conditions ===== ===== Conditions =====
줄 251: 줄 251:
 ''when:'' ''when:''
  
-  * var == "Vaue", var >= 5, etc. +  * ''var == "Vaue"''''var >= 5'', etc. 
-  * var, where var coreces to boolean (yes, true, True, TRUE) +  * ''var'', where ''var'' coreces to boolean (yes, true, True, TRUE) 
-  * var is defined, var is not defined +  * ''var is defined''''var is not defined'' 
-  * <condition1> and <condition2> (also or?)+  * ''<nowiki><condition1> and <condition2></nowiki>'' (also or?)
  
 Combined with ''with_items'', the when statement is processed for each item. Combined with ''with_items'', the when statement is processed for each item.
줄 460: 줄 460:
 ==== First found: ==== ==== First found: ====
  
 +<WRAP prewrap>
 +<code yaml>
 - name: template a file - name: template a file
   template: src={{ item }} dest=/etc/myapp/foo.conf   template: src={{ item }} dest=/etc/myapp/foo.conf
줄 703: 줄 705:
 ==== ansible-pull ==== ==== ansible-pull ====
  
 +<WRAP prewrap>
 +<code bash>
 Usage: ansible-pull [options] [playbook.yml] Usage: ansible-pull [options] [playbook.yml]
  
  • ansible_summary.1536114137.txt.gz
  • 마지막으로 수정됨: 2018/09/05 02:22
  • 저자 koov