<h5 dir="auto">ISSUE TYPE</h5>
<ul dir="auto">
<li>Bug Report</li>
</ul>
<h5 dir="auto">COMPONENT NAME</h5>
<p dir="auto">ansible-vault</p>
<h5 dir="auto">ANSIBLE VERSION</h5>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible-vault 2.4.0.0
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['&lt;home_dir&gt;/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /opt/envs/ansible/lib/python3.6/site-packages/ansible
  executable location = /opt/envs/ansible/bin/ansible-vault
  python version = 3.6.1 (default, Apr 22 2017, 00:00:00) [GCC 4.8.4]"><pre class="notranslate"><code class="notranslate">ansible-vault 2.4.0.0
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['&lt;home_dir&gt;/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /opt/envs/ansible/lib/python3.6/site-packages/ansible
  executable location = /opt/envs/ansible/bin/ansible-vault
  python version = 3.6.1 (default, Apr 22 2017, 00:00:00) [GCC 4.8.4]
</code></pre></div>
<h5 dir="auto">CONFIGURATION</h5>
<p dir="auto">No changes to config</p>
<h5 dir="auto">OS / ENVIRONMENT</h5>
<p dir="auto">Ubuntu 14.04</p>
<h5 dir="auto">SUMMARY</h5>
<p dir="auto">ansible-vault decrypt does not print to stdout</p>
<h5 dir="auto">STEPS TO REPRODUCE</h5>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt; echo &quot;hello&quot; &gt; /tmp/foo
&gt; ansible-vault encrypt /tmp/foo
Encryption successful
&gt; ansible-vault decrypt /tmp/foo --output -
Decryption successful"><pre class="notranslate"><code class="notranslate">&gt; echo "hello" &gt; /tmp/foo
&gt; ansible-vault encrypt /tmp/foo
Encryption successful
&gt; ansible-vault decrypt /tmp/foo --output -
Decryption successful
</code></pre></div>
<h5 dir="auto">EXPECTED RESULTS</h5>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="hello
Decryption successful"><pre class="notranslate"><code class="notranslate">hello
Decryption successful
</code></pre></div>
<h5 dir="auto">ACTUAL RESULTS</h5>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Decryption successful"><pre class="notranslate"><code class="notranslate">Decryption successful
</code></pre></div>
<p dir="auto"><strong>ansible-vault==2.3.1.0 yields the expected output.</strong></p>
<p dir="auto"><em>Additional question: Is it possible to suppress "Decryption successful" as I would like to use the output in a script.</em></p>
<h5 dir="auto">ANSIBLE VERSION</h5>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible 2.4.0.0"><pre class="notranslate"><code class="notranslate">ansible 2.4.0.0
</code></pre></div>
<p dir="auto">In ansible 2.3.x, it was possible to do <code class="notranslate">ansible-vault decrypt example.txt --output -</code> to get the decrypted output into stdout. In fact, that is advertised in <code class="notranslate">ansible-vault decrypt --help</code>:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="  --output=OUTPUT_FILE  output file name for encrypt or decrypt; use - for stdout"><pre class="notranslate"><code class="notranslate">  --output=OUTPUT_FILE  output file name for encrypt or decrypt; use - for stdout
</code></pre></div>
<p dir="auto">In Ansible 2.4, this is bugged and results in a file named <code class="notranslate">-</code>.</p>