-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
44 lines (30 loc) · 836 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
FROM debian:bullseye
ARG UID
ARG USER
# install minimal tools
RUN apt-get update
RUN apt-get install -y \
curl \
git \
python3 \
python3-pip \
sudo \
tmux
RUN pip3 install awscli
# fix locale for tmux
RUN apt-get install -y locales
RUN echo "en_US.UTF-8 UTF-8" > /etc/locale.gen
RUN locale-gen
# fix user
RUN useradd -m -u ${UID} -g sudo -s /bin/bash ${USER}
RUN echo "${USER} ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
USER ${USER}
RUN echo 'PS1="DOCKER > \w \$ "' >> ~/.bashrc
# install Rust
RUN curl -LSso /tmp/rustup.sh https://sh.rustup.rs
RUN sh /tmp/rustup.sh -y
RUN echo "PATH=~/.cargo/bin:\$PATH" >> ~/.bashrc
RUN ~/.cargo/bin/rustup component add rust-analyzer rust-src
RUN ln -s `~/.cargo/bin/rustup which --toolchain stable rust-analyzer` ~/.cargo/bin/
RUN ~/.cargo/bin/cargo install sssg
EXPOSE 1337