-
Notifications
You must be signed in to change notification settings - Fork 74
/
Dockerfile
38 lines (33 loc) · 1.02 KB
/
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
# BUILD-USING: docker build -t derbyjs/derby-examples .
# RUN-USING: docker run --name derby-examples --rm derbyjs/derby-examples
# specify base docker image
FROM node:20
# copy over dependencies
WORKDIR /var
RUN mkdir derby-examples
ADD package.json /var/derby-examples/
ADD server.js /var/derby-examples/
ADD charts /var/derby-examples/charts
ADD chat /var/derby-examples/chat
ADD codemirror /var/derby-examples/codemirror
ADD directory /var/derby-examples/directory
ADD hello /var/derby-examples/hello
ADD sink /var/derby-examples/sink
ADD todos /var/derby-examples/todos
ADD widgets /var/derby-examples/widgets
ADD render /var/derby-examples/render
# npm install all the things
WORKDIR /var/derby-examples
RUN npm_config_spin=false npm_config_loglevel=warn npm install --production
# expose any ports we need
EXPOSE 8001
EXPOSE 8002
EXPOSE 8003
EXPOSE 8004
EXPOSE 8005
EXPOSE 8006
EXPOSE 8007
EXPOSE 8008
EXPOSE 8009
# the command that gets run inside the docker container
CMD ["/usr/local/bin/node", "/var/derby-examples/server.js"]