Skip to content

Commit 039cf10

Browse files
authored
Merge pull request #40 from aminya/cpath [skip ci]
2 parents 9b3ba25 + 99fd4a9 commit 039cf10

File tree

17 files changed

+118
-49
lines changed

17 files changed

+118
-49
lines changed

.github/workflows/CI.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,9 @@ jobs:
8787
matrix:
8888
os:
8989
- ubuntu-20.04
90+
container:
91+
- "ubuntu_node.dockerfile"
92+
- "ubuntu_stable_node.dockerfile"
9093
node:
9194
- 14
9295
pnpm:
@@ -124,6 +127,6 @@ jobs:
124127
- name: Build
125128
id: docker_build
126129
run: |
127-
pnpm build.docker
130+
docker build -f ./building/docker/${{ matrix.container }} -t setup_cpp .
128131
env:
129132
ACTIONS_ALLOW_UNSECURE_COMMANDS: true

README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -178,8 +178,7 @@ jobs:
178178
Here is an example for using setup_cpp to make a builder image that has the Cpp tools you need.
179179

180180
```dockerfile
181-
# debian
182-
FROM debian:bullseye
181+
FROM ubuntu:devel
183182

184183
# add setup_cpp
185184
WORKDIR "/"
@@ -202,7 +201,7 @@ See [this folder](https://github.com/aminya/setup-cpp/tree/master/building/docke
202201
If you want to build the ones included, then run:
203202

204203
```ps1
205-
docker build -f ./building/docker/debian.dockerfile -t setup_cpp .
204+
docker build -f ./building/docker/ubuntu.dockerfile -t setup_cpp .
206205
```
207206

208207
Where you should use the path to the dockerfile after `-f`.
@@ -242,7 +241,7 @@ The following gives an example for setting up a C++ environment inside GitLab pi
242241
.gitlab-ci.yaml
243242
244243
```yaml
245-
image: ubuntu:latest
244+
image: ubuntu:devel
246245

247246
stages:
248247
- test

building/docker/debian_node_slim.dockerfile

Lines changed: 0 additions & 14 deletions
This file was deleted.

building/docker/debian.dockerfile renamed to building/docker/ubuntu.dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
# debian
2-
FROM debian:bullseye
1+
FROM ubuntu:devel
32

43
# add setup_cpp
54
WORKDIR "/"

building/docker/debian_node.dockerfile renamed to building/docker/ubuntu_node.dockerfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
1-
# debian with node installed
2-
FROM node:16
1+
FROM ubuntu:devel
2+
3+
RUN apt-get update -qq
4+
RUN apt-get install -y --no-install-recommends nodejs
35

46
# add setup_cpp.js
57
ADD "./dist/" "/"
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
FROM ubuntu:latest
2+
3+
# set time-zone
4+
ENV TZ=Canada/Pacific
5+
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
6+
7+
# The nodejs that ships on ubuntu:latest servers is too old.
8+
ENV DEBIAN_FRONTEND=noninteractive
9+
RUN apt-get update -qq
10+
RUN apt-get install -y --no-install-recommends curl gnupg ca-certificates
11+
RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -
12+
RUN apt-get install -y --no-install-recommends nodejs
13+
14+
# add setup_cpp.js
15+
ADD "./dist/" "/"
16+
WORKDIR "/"
17+
18+
# run installation
19+
RUN node ./setup_cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true
20+
21+
# reload the environment and print the versions
22+
CMD source ~/.profile && clang --version && cmake --version && ninja --version && ccache --version && cppcheck --version && vcpkg --version && doxygen --version && dot --version && gcovr --version
23+
24+
ENTRYPOINT [ "/bin/sh" ]

dist/setup_cpp.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/setup_cpp.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
},
1414
"scripts": {
1515
"build": "cross-env NODE_ENV=production parcel build --detailed-report && npm run copy.matchers",
16-
"build.docker": "pnpm build && docker build -f ./building/docker/debian_node.dockerfile -t setup_cpp .",
16+
"build.docker": "pnpm build && docker build -f ./building/docker/ubuntu_node.dockerfile -t setup_cpp .",
1717
"bump": "ncu -u -x execa",
1818
"clean": "shx rm -rf .parcel-cache dist exe",
1919
"copy.matchers": "shx cp ./src/gcc/gcc_matcher.json ./dist/ && shx cp ./src/msvc/msvc_matcher.json ./dist && shx cp ./src/python/python_matcher.json ./dist/ && shx cp ./src/llvm/llvm_matcher.json ./dist/ ",

src/default_versions.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const DefaultVersions: Record<string, string> = {
1010
python: "3.8.10",
1111
kcov: "v39",
1212
task: "3.10.0",
13-
doxygen: process.platform === "win32" ? "1.9.3.20220106" : "1.9.3",
13+
doxygen: "1.9.2",
1414
gcc: process.platform === "win32" ? "11.2.0.07112021" : "11",
1515
}
1616

0 commit comments

Comments
 (0)