title: Getting DisconnectableInputStream source reader while trying to run Gradle Build
body: <p>I have a script that runs a <code>gradle build</code> like this...</p>
  
  <pre><code>$HOME_DIR$CODE_DIR/gradlew -p $HOME_DIR$CODE_DIR build
  </code></pre>
  
  <p>When I run this regularly like <code>./start.local.sh</code> it works fine. But when I try to use nohup like <code>nohup ./start.local.sh &amp;</code> I get...</p>
  
  <pre><code>Exception in thread "DisconnectableInputStream source reader" org.gradle.api.UncheckedIOException: java.io.IOException: Bad file descriptor
      at org.gradle.internal.UncheckedException.throwAsUncheckedException(UncheckedException.java:57)
      at org.gradle.internal.UncheckedException.throwAsUncheckedException(UncheckedException.java:40)
      at org.gradle.util.DisconnectableInputStream$1.run(DisconnectableInputStream.java:125)
      at java.base/java.lang.Thread.run(Thread.java:844)
  Caused by: java.io.IOException: Bad file descriptor
  </code></pre>
  
  <p>What am I missing?</p>