forked from ryankurte/docker-ns3
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
60 lines (60 loc) · 1.19 KB
/
Dockerfile
File metadata and controls
60 lines (60 loc) · 1.19 KB
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
FROM ubuntu:20.04
LABEL Description="Docker image for NS-3 Network Simulator"
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
# General dependencies
RUN apt-get install -y \
git \
mercurial \
wget \
vim \
nano \
autoconf \
bzr \
cvs \
unrar \
build-essential \
clang \
valgrind \
gsl-bin \
libgsl-dev \
libgslcblas0 \
flex \
bison \
libfl-dev \
tcpdump \
tshark \
sqlite3 \
libsqlite3-dev \
libxml2 \
libxml2-dev \
vtun \
lxc
# QT4 components
RUN apt-get install -y \
qtbase5-dev
# Python components
RUN apt-get install -y \
python3 \
python3-dev \
python3-setuptools \
cmake \
libc6-dev \
libc6-dev-i386 \
g++-multilib
# Create python symlink for compatibility
RUN ln -s /usr/bin/python3 /usr/bin/python
# NS-3
# Create working directory
RUN mkdir -p /usr/ns3
WORKDIR /usr
# Fetch NS-3 source
RUN wget http://www.nsnam.org/release/ns-allinone-3.29.tar.bz2
RUN tar -xf ns-allinone-3.29.tar.bz2
# Configure and compile NS-3
RUN cd ns-allinone-3.29 && python3 ./build.py --enable-examples --enable-tests
RUN ln -s /usr/ns-allinone-3.29/ns-3.29/ /usr/ns3/
# Cleanup
RUN apt-get clean && \
rm -rf /var/lib/apt && \
rm /usr/ns-allinone-3.29.tar.bz2