-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
71 lines (55 loc) · 1.31 KB
/
Dockerfile
File metadata and controls
71 lines (55 loc) · 1.31 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
61
62
63
64
65
66
67
68
69
70
71
####
# Pull base image.
####
FROM ubuntu:18.04
####
# Install Node.js
####
RUN apt-get update
RUN apt-get install --yes wget
RUN wget -qO- https://deb.nodesource.com/setup_8.x | bash -
RUN apt-get install --yes nodejs
####
# Install build tools
####
RUN apt-get install --yes build-essential libpcap-dev zlib1g-dev libfuse-dev pkg-config fuse git libtool
####
# Build MooseFS client from source
####
RUN git clone https://github.com/moosefs/moosefs.git /moosefs
WORKDIR /moosefs
RUN git checkout v3.0.105
#RUN autoreconf -f -i
RUN ./linux_build.sh
RUN make install
####
# Remove build tools
####
RUN apt-get purge --yes build-essential pkg-config
RUN apt-get autoremove --yes
####
# Install Docker volume driver API server
####
# Create directories for mounts
RUN mkdir -p /mnt/moosefs
RUN mkdir -p /mnt/docker-volumes
# Copy in package.json
COPY package.json package-lock.json /project/
# Switch to the project directory
WORKDIR /project
# Install project dependencies
RUN npm install
# Set Configuration Defaults
ENV HOST=mfsmaster \
PORT=9421 \
ALIAS=moosefs \
ROOT_VOLUME_NAME="" \
MOUNT_OPTIONS="" \
REMOTE_PATH=/docker/volumes \
LOCAL_PATH="" \
CONNECT_TIMEOUT=10000 \
LOG_LEVEL=info
# Copy in source code
COPY index.js /project
# Set the Docker entrypoint
ENTRYPOINT ["node", "index.js"]