File tree Expand file tree Collapse file tree 3 files changed +27
-28
lines changed Expand file tree Collapse file tree 3 files changed +27
-28
lines changed Original file line number Diff line number Diff line change 1
- .git /
2
- .appends /
3
- .github /
4
- .gitattributes
5
- .gitignore
6
- Dockerfile
7
- bin / run-in-docker.sh
8
- bin / run-tests-in-docker.sh
9
- tests /
10
- output /
11
- open-abap /
1
+ # Ignore everything to act as an allow list
2
+ *
3
+
4
+ # Include application files
5
+ ! bin / run.sh
6
+ ! extra /
7
+ ! src /
8
+ ! test /
9
+ ! package-lock.json
10
+ ! package.json
11
+ ! tsconfig.json
Original file line number Diff line number Diff line change 1
- FROM node:lts-slim
1
+ FROM node:lts-alpine
2
2
3
- RUN apt-get -y update
4
- RUN apt-get -y upgrade
5
- RUN apt-get -y install git
6
- RUN apt-get clean
7
- RUN rm -rf /var/lib/apt/lists/*
8
-
9
-
10
- RUN npm --version
11
-
12
- # The docker container is run without network access, so dont check for updates
3
+ # Note: The docker container is run without network access
13
4
ENV NO_UPDATE_NOTIFIER=true
14
5
15
6
WORKDIR /opt/test-runner
16
7
COPY . .
17
- RUN npm ci
18
- RUN npm run build
19
- RUN npm install @abaplint/cli -g
20
- RUN npm install @abaplint/transpiler-cli -g
21
- RUN npm install @abaplint/runtime -g
22
- ENTRYPOINT ["/opt/test-runner/bin/run.sh" ]
8
+ RUN apk add --no-cache --virtual .build-deps git \
9
+ && npm ci \
10
+ && npm run build \
11
+ && apk del .build-deps \
12
+ # Remove build time depencies
13
+ && npm prune --omit dev \
14
+ # FIXME: These dependencies are required globally while they are included in package.json
15
+ && npm install --global @abaplint/cli @abaplint/transpiler-cli @abaplint/runtime \
16
+ # Clean npm generated files
17
+ && npm cache clean --force \
18
+ && rm -rf /tmp/* /root/.npm
19
+
20
+ ENTRYPOINT ["/opt/test-runner/bin/run.sh" ]
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ docker run \
20
20
--rm \
21
21
--network none \
22
22
--read-only \
23
+ --mount type=bind,source=" ${PWD} /bin/run-tests.sh" ,destination=/opt/test-runner/bin/run-tests.sh \
23
24
--mount type=bind,src=" ${PWD} /tests" ,dst=/opt/test-runner/tests \
24
25
--mount type=tmpfs,dst=/tmp \
25
26
--workdir /opt/test-runner \
You can’t perform that action at this time.
0 commit comments