-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
36 lines (28 loc) · 983 Bytes
/
Dockerfile
File metadata and controls
36 lines (28 loc) · 983 Bytes
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
FROM ubuntu:22.04
LABEL docknet.docker.version="1"
# System update
RUN apt-get update
RUN apt-get upgrade -y
RUN apt-get dist-upgrade -y
# Set locale
RUN apt-get install -y locales
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
# Python and common tools
RUN apt-get install -y software-properties-common
RUN add-apt-repository -y ppa:deadsnakes/ppa
RUN DEBIAN_FRONTEND=noninteractive TZ=Europe/Dublin apt-get -y install tzdata
RUN apt-get install -y python3.9 python3.9-dev python3.9-venv
# Create Docker user
RUN useradd -ms /bin/bash docker
# Copy the Docknet repo into the Docker container
ADD . /home/docker/docknet
# Make the docker user the docknet folder owner
RUN chown -R docker:docker /home/docker/docknet
# Run build script as the docknet user to install the package and run the tests
USER docker
WORKDIR /home/docker/docknet
RUN delivery/scripts/build.sh
CMD . /home/docker/docknet_venv/bin/activate && docknet_start