-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
45 lines (30 loc) · 956 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
39
40
41
42
43
44
45
# Build the frontend
FROM node:latest as build
# Set working directory for frontend
WORKDIR /app
# Copy package.json and package-lock.json
COPY . .
# Install npm dependencies
RUN npm install --force
RUN npm install grunt-cli -g --force
RUN grunt
# Use an ubuntu image
FROM ubuntu:latest
# Update the package lists and install Nginx
RUN apt-get update && apt-get install -y nginx
# Remove default Nginx configuration
RUN rm /etc/nginx/sites-enabled/default
# Install OpenJDK 11
RUN apt-get install -y openjdk-11-jdk
# Copy the contents of your HTML folder to the container
COPY --from=build /app/deploy /var/www/html
# Start Fuseki & Nginx server
WORKDIR /fuseki
COPY --from=build /app/libs/fuseki .
# Copy the custom Nginx configuration file
COPY nginx.conf /etc/nginx/nginx.conf
# Expose port 8000,3030
EXPOSE 8000
EXPOSE 3030
# Start Nginx service
CMD java -jar fuseki-server.jar --update --loc=db /dataset & nginx -g "daemon off;"