forked from Astron/Astron
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
38 lines (32 loc) · 911 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
# Dockerfile for Building and Running Astron
# Use the latest Ubuntu as the base image
FROM ubuntu:latest
# Install necessary dependencies to build Astron
RUN apt-get update && \
apt-get install -y \
cmake \
libyaml-cpp-dev \
libmongoclient-dev \
llvm \
libboost-dev \
clang \
g++ \
gcc \
libuv1-dev
# Copy the local source directory into the container and set the working directory
COPY . /app-src
WORKDIR /app-src
# Build Astron using the build type supplied as a build argument
ARG BUILD_TYPE=Release
RUN mkdir -p /app/build && \
cd /app/build && \
cmake -DCMAKE_BUILD_TYPE=${BUILD_TYPE} /app-src && \
make && \
mv astrond /app && \
rm -rf /app-src && \
rm -rf /app/build
# Set the working directory to /app and set the startup script as the entrypoint
WORKDIR /app
COPY startup.sh .
RUN chmod +x startup.sh
ENTRYPOINT [ "./startup.sh" ]