title: Docker fails to build a Nestjs app with node-crc (rust cargo)
body: <p>I have the following <code>Dockerfile</code> for my project and I have troubles with building my Nest.js app since one of my dependencies is <code>&quot;node-crc&quot;: &quot;2.0.13&quot;</code> which somehow fails to build during the <code>docker build</code> command.</p>
  <pre><code>FROM node:17.3.1-alpine
  
  RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
  
  ENV PATH=&quot;/root/.cargo/bin:${PATH}&quot;
  
  WORKDIR /usr/src/app
  
  RUN npm install -g @nestjs/cli
  
  COPY package.json ./
  
  RUN yarn install
  
  ...SOME OTHER CMDs NOT IMPORTANT TO CASE
  </code></pre>
  <p>When I use <code>yarn install</code> within my project folder, it cause no errors (I use Win11) and node actually works fine, but during the docker image building stage (via WSL 2.0) I got the following error:</p>
  <pre><code> &gt; [6/8] RUN yarn install:
  #11 102.3 [4/4] Building fresh packages...
  #11 102.7 error /usr/src/app/node_modules/node-crc: Command failed.
  #11 102.7 Exit code: 1
  #11 102.7 Command: npm run build:neon
  #11 102.7 Arguments:
  #11 102.7 Directory: /usr/src/app/node_modules/node-crc
  #11 102.7 Output:
  #11 102.7 &gt; node-crc@2.0.13 build:neon
  #11 102.7 &gt; cargo-cp-artifact -nc index.node -- cargo build --release --message-format=json-render-diagnostics
  #11 102.7
  #11 102.7 Error: could not find the `cargo` executable.
  #11 102.7
  #11 102.7 You can find instructions for installing Rust and Cargo at:
  #11 102.7
  #11 102.7     https://www.rust-lang.org/tools/install
  #11 102.7
  #11 102.7
  #11 102.7 Did not copy &quot;cdylib:node-crc&quot;
  #11 102.7 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
  </code></pre>
  <p>So, the question is: <em>How does this possible?</em> Espesially after I modify script with <code> RUN curl https://sh.rustup.rs -sSf | sh -s -- -y</code> which actually should install the necessary rush-cargo build dependency?</p>