-
-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
did not build due to missing dependecies, create a docker image that have them predownloaded.
- Loading branch information
Showing
6 changed files
with
40 additions
and
8 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
FROM node:10-alpine | ||
FROM node:14-alpine | ||
|
||
WORKDIR / | ||
COPY . . | ||
|
||
RUN npm install --quiet | ||
RUN apk update && apk add -q git && npm install --quiet | ||
|
||
ENTRYPOINT [ "npm", "run-script", "build" ] | ||
ENTRYPOINT [ "npm", "run-script", "build" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
FROM multiarch/qemu-user-static:x86_64-arm as qemu | ||
|
||
FROM arm32v7/node:14-stretch-slim | ||
COPY --from=qemu /usr/bin/qemu-arm-static /usr/bin | ||
|
||
RUN apt-get update && apt-get install -y git ca-certificates subversion --no-install-recommends && rm -rf /var/lib/apt/lists/* | ||
|
||
# Get prebuilt node binaries and rename them to what node tries to fetch, ugly hack, but work more reliable compared to previous method. | ||
RUN mkdir -p ~/.pkg-cache/ && cd ~/.pkg-cache/ && svn export https://github.com/Hypfer/Valetudo.git/trunk/build_dependencies/pkg/v2.6 && chmod +x ~/.pkg-cache/*/* && rename 's/built/fetched/g' ~/.pkg-cache/*/* && rename 's,v14.16.0,v14.4.0,g' ~/.pkg-cache/*/* && ls -la ~/.pkg-cache/*/* | ||
WORKDIR /src | ||
COPY . . | ||
|
||
RUN npm install --quiet |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,21 @@ | ||
PATH := node_modules/.bin:$(PATH) | ||
SHELL := /bin/bash | ||
PKG ?= pkg | ||
|
||
.PHONY: all clean | ||
DOCKER ?= docker | ||
.PHONY: all clean docker.roborock build.roborock | ||
|
||
all: | ||
npm run build | ||
|
||
clean: | ||
rm -f valetudo | ||
|
||
docker.roborock: | ||
$(DOCKER) build -t roborock:build -f Dockerfile.roborock . | ||
|
||
.in_docker: | ||
bash -c "npm run-script build || cat /root/.npm/_logs/* && ls -la ~/.pkg-cache/*/*" | ||
|
||
build.roborock: | ||
$(DOCKER) run -v $(abspath .):/ws -it -t roborock:build bash -c "npm run-script build || cat /root/.npm/_logs/* && ls -la ~/.pkg-cache/*/*" | ||
# bash -c "make -C /ws .in_docker" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters