Skip to content

Commit e257d66

Browse files
committed
Actually fix dev container
1 parent 9453b3f commit e257d66

File tree

3 files changed

+18
-12
lines changed

3 files changed

+18
-12
lines changed

.devcontainer/Dockerfile

+16-6
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,21 @@
1-
FROM rust:1-buster
1+
FROM ubuntu:22.04
22

33
RUN apt-get update && \
4-
DEBIAN_FRONTEND=noninteractive apt-get install -y curl python3 python3-pip make gcc && \
5-
curl -fsSL https://deb.nodesource.com/setup_21.x | bash - && \
6-
apt-get install -y nodejs
4+
DEBIAN_FRONTEND=noninteractive apt-get install -y curl python3 python3-pip make gcc git pkg-config libssl-dev
75

8-
RUN rustup component add clippy
6+
RUN curl -fsSL https://deb.nodesource.com/setup_21.x | bash - && \
7+
DEBIAN_FRONTEND=noninteractive apt-get install -y nodejs
8+
9+
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && \
10+
echo "source $HOME/.cargo/env" >> $HOME/.bashrc
11+
12+
RUN $HOME/.cargo/bin/rustup component add clippy
13+
14+
RUN $HOME/.cargo/bin/rustup target add wasm32-unknown-unknown
15+
16+
RUN . $HOME/.cargo/env && \
17+
curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
918

1019
COPY Makefile /tmp/Makefile
11-
RUN make -j -f /tmp/Makefile dependencies
20+
RUN . $HOME/.cargo/env && \
21+
make -f /tmp/Makefile dependencies

.devcontainer/devcontainer.json

-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
// Increase size of temporary in-memory filesystem for auto-generated binaries by test scripts
1717
"--shm-size=1G"
1818
],
19-
"onCreateCommand": "curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh && echo \"Installing dependencies, this might take a while...\" && make dependencies",
2019
// Use 'postCreateCommand' to run commands after the container is created.
2120
// "postCreateCommand": "rustc --version",
2221
// Configure tool-specific properties.

Makefile

+2-5
Original file line numberDiff line numberDiff line change
@@ -150,12 +150,9 @@ watch-programs:
150150
######################
151151
### Utilities
152152
######################
153-
dependencies: python-dependencies
153+
dependencies:
154154
cargo install cargo-tarpaulin cargo-watch python-launcher
155-
156-
python-dependencies:
157-
$(PY) -m pip install pyperclip tqdm
158-
155+
py -3 -m pip install pyperclip tqdm
159156

160157
clean:
161158
rm -rf $(RM_TARGETS)

0 commit comments

Comments
 (0)