osrm-backend/docker-orchestration/osrm-frontend-docker/Dockerfile
CoderBear801 5fcfab1046 feat: Add docker image for OSRM frontend
- docker image contains OSRM frontend and nginx
2019-06-14 17:14:53 -07:00

29 lines
605 B
Docker
Executable File

FROM node
RUN apt-get update && apt-get install -y \
nginx \
git \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# forward request and error logs to docker log collector
RUN ln -sf /dev/stdout /var/log/nginx/access.log \
&& ln -sf /dev/stderr /var/log/nginx/error.log
ENV work_dir /app
WORKDIR ${work_dir}
# install OSRM-front
RUN git clone https://github.com/Project-OSRM/osrm-frontend.git .
COPY ./osrm_options.js ./src/leaflet_options.js
RUN npm install
RUN make
# configure nginx
COPY ./nginx.conf /etc/nginx/sites-enabled/default
EXPOSE 80
COPY ./start.sh ./start.sh
CMD ./start.sh