diff --git a/Dockerfile.builder b/Dockerfile.builder index b487e2d..e062bc9 100644 --- a/Dockerfile.builder +++ b/Dockerfile.builder @@ -21,6 +21,8 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-ins RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal ENV PATH="/root/.cargo/bin:$PATH" +# Keep Rust/Tauri builds from saturating the small app server. +ENV CARGO_BUILD_JOBS=1 RUN rustup target add x86_64-pc-windows-msvc \ && cargo install --locked cargo-xwin @@ -35,7 +37,7 @@ COPY . . # the desktop app itself without creating updater signatures. RUN node -e "const fs=require('fs'); const p='src-tauri/tauri.conf.json'; const c=JSON.parse(fs.readFileSync(p,'utf8')); c.bundle.createUpdaterArtifacts=false; fs.writeFileSync(p, JSON.stringify(c,null,2)+'\\n')" -RUN npm run bundle:windows +RUN nice -n 10 npm run bundle:windows RUN set -eux; \ mkdir -p /desktop-artifacts; \ diff --git a/Dockerfile.builder-linux b/Dockerfile.builder-linux index a73cca0..2fc7488 100644 --- a/Dockerfile.builder-linux +++ b/Dockerfile.builder-linux @@ -17,6 +17,8 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-ins RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal ENV PATH="/root/.cargo/bin:$PATH" +# Keep Rust/Tauri builds from saturating the small app server. +ENV CARGO_BUILD_JOBS=1 COPY package.json ./ RUN npm install @@ -25,7 +27,7 @@ COPY . . RUN node -e "const fs=require('fs'); const p='src-tauri/tauri.conf.json'; const c=JSON.parse(fs.readFileSync(p,'utf8')); c.bundle.createUpdaterArtifacts=false; fs.writeFileSync(p, JSON.stringify(c,null,2)+'\\n')" -RUN npm run bundle:deb +RUN nice -n 10 npm run bundle:deb RUN set -eux; \ mkdir -p /desktop-artifacts; \