35 lines
1,005 B
Docker
35 lines
1,005 B
Docker
|
# syntax=docker/dockerfile:1
|
||
|
FROM ubuntu:20.04
|
||
|
LABEL Description="CORE Docker Ubuntu Image"
|
||
|
|
||
|
# define variables
|
||
|
ARG PREFIX=/usr/local
|
||
|
ARG BRANCH=master
|
||
|
|
||
|
# define environment
|
||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||
|
|
||
|
# install core
|
||
|
RUN apt-get update && \
|
||
|
apt-get install -y git sudo wget tzdata
|
||
|
WORKDIR /root
|
||
|
RUN git clone https://github.com/coreemu/core
|
||
|
WORKDIR /root/core
|
||
|
RUN git checkout ${BRANCH}
|
||
|
RUN ./setup.sh
|
||
|
RUN . /root/.bashrc && inv install -v -p ${PREFIX}
|
||
|
# install emane packages and python bindings
|
||
|
WORKDIR /root
|
||
|
RUN wget -q https://adjacentlink.com/downloads/emane/emane-1.3.3-release-1.ubuntu-20_04.amd64.tar.gz && \
|
||
|
tar xf emane*.tar.gz && \
|
||
|
cd emane-1.3.3-release-1/debs/ubuntu-20_04/amd64 && \
|
||
|
apt-get install -y ./emane*.deb ./python3-emane_*.deb && \
|
||
|
cd ../../../.. && \
|
||
|
rm emane-1.3.3-release-1.ubuntu-20_04.amd64.tar.gz && \
|
||
|
rm -rf emane-1.3.3-release-1
|
||
|
WORKDIR /root/core
|
||
|
RUN . /root/.bashrc && inv install-emane -v -e v1.3.3
|
||
|
|
||
|
# run daemon
|
||
|
CMD ["core-daemon"]
|