title: Fix umask for future RUN commands in dockerfile
body: <p>I would like to fix a certain umask for all my RUN commands in the remainder of a dockerfile. Instead of writing this</p>
  
  <pre><code>RUN umask 0002 &amp;&amp; do_something
  </code></pre>
  
  <p>I would like to do something like this</p>
  
  <pre><code>RUN echo umask 0002 &gt;&gt; some_file
  RUN do_something
  ...
  </code></pre>
  
  <p>I have tried setting the umask for <code>root</code> in various ways but none of them seem to take effect on the following <code>RUN</code> commands. Any ideas?</p>