File size: 580 Bytes
c563042
 
fcd9c93
e798e68
fcd9c93
 
c563042
fcd9c93
 
e798e68
 
 
c563042
fcd9c93
 
e798e68
 
be10950
c563042
aabb39f
e798e68
 
 
c563042
e798e68
be10950
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
# Use Node.js 18 as the base image
FROM node:18

# Set working directory inside the container
WORKDIR /app

# Clone your GitHub repository
RUN git clone https://github.com/jonellcc/jonellccprojectsapis.git /app

# Set full read/write/execute permissions for all files & directories
RUN chmod -R 777 /app

# Change to the cloned repository directory
WORKDIR /app

# Install dependencies (if needed)
RUN npm install  

# Expose the necessary port (modify based on your API)
EXPOSE 8080

# Run as root to avoid permission issues
USER root

# Start the server
CMD ["node", "index.js"]