-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
62 lines (57 loc) · 1.48 KB
/
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
FROM ubuntu:20.04
# Install system packages
RUN DEBIAN_FRONTEND="noninteractive" apt-get update && apt-get -y install tzdata
RUN apt-get update \
&& apt-get install -y \
openssh-server \
sudo \
ssh \
\
python3-pip \
python3-dev \
python3-venv \
libevent-dev \
\
vim \
\
gcc \
g++ \
gdb \
clang \
cmake \
make \
build-essential \
autoconf \
automake \
valgrind \
software-properties-common \
\
rsync \
tar \
tree \
wget \
&& apt-get clean
# ninja-build \
# neovim \
# swig \
# \
# locales-all \
# dos2unix \
# \
# doxygen \
# fish \
WORKDIR /home/ubuntu
# Prepare project for running
# Must be in this stupid way, because gym has some problems with `pip install -r requirements.txt`
# and gymnasium can't be used, because stable-baseline3 is not compatible with gymnasium
COPY requirements.txt /home/ubuntu/
RUN sudo python3 -m venv /home/ubuntu/venv \
&& sudo /home/ubuntu/venv/bin/pip install --upgrade pip \
&& for i in $(cat requirements.txt);do sudo /home/ubuntu/venv/bin/pip install ${i};done
# Setup SSH: username=user:password=user
RUN useradd -rm -d /home/ubuntu -s /bin/bash -g root -G sudo -u 1000 user
RUN echo 'user:user' | chpasswd
RUN service ssh start
# Port to expose and Entrypoint
EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]