2024-09-21 09:23:24 +03:00
|
|
|
FROM nick1udwig/buildbase:latest
|
|
|
|
|
2024-09-28 05:05:34 +03:00
|
|
|
ARG DOCKER_BUILD_IMAGE_VERSION=latest
|
2024-09-21 09:23:24 +03:00
|
|
|
|
2024-09-28 05:05:34 +03:00
|
|
|
ENV NVM_DIR=/root/.nvm \
|
|
|
|
PATH="/root/.nvm/versions/node/$(node -v)/bin:${PATH}" \
|
|
|
|
DOCKER_BUILD_IMAGE_VERSION=$DOCKER_BUILD_IMAGE_VERSION
|
2024-09-21 09:23:24 +03:00
|
|
|
|
2024-09-24 18:34:05 +03:00
|
|
|
# Bind readonly & copy files in to avoid modifying host files
|
2024-09-24 18:38:29 +03:00
|
|
|
WORKDIR /input
|
2024-09-21 09:23:24 +03:00
|
|
|
|
|
|
|
# Set the default command to run the build script
|
2024-09-24 18:34:05 +03:00
|
|
|
# TODO: once build is idempotent, remove the `rm -rf` line
|
2024-10-09 00:02:47 +03:00
|
|
|
CMD ["/bin/bash", "-c", ". ~/.bashrc && . ~/.cargo/env && . $NVM_DIR/nvm.sh && ./scripts/build-release.py && cp -r /tmp/kinode-release/* /output && chmod 664 /output/* && find . -user root -print0 2>/dev/null | xargs -0 rm -rf"]
|