create-bluecopa-react-app 1.0.9 → 1.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/templates/latest/.dockerignore +1 -0
- package/templates/latest/Dockerfile +27 -20
- package/templates/latest/package-lock.json +2097 -847
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
node_modules/
|
|
@@ -1,22 +1,29 @@
|
|
|
1
|
-
FROM node:
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
COPY
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
COPY
|
|
14
|
-
|
|
1
|
+
FROM node:18-alpine AS production
|
|
2
|
+
|
|
3
|
+
# Set working directory
|
|
4
|
+
WORKDIR /usr/src/app
|
|
5
|
+
|
|
6
|
+
# Copy package files
|
|
7
|
+
COPY package*.json ./
|
|
8
|
+
|
|
9
|
+
# Install dependencies
|
|
10
|
+
RUN npm install
|
|
11
|
+
|
|
12
|
+
# Copy source code
|
|
13
|
+
COPY . .
|
|
14
|
+
|
|
15
|
+
# Build the application
|
|
15
16
|
RUN npm run build
|
|
16
17
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
# Install serve globally
|
|
19
|
+
RUN npm install -g serve@14.2.0
|
|
20
|
+
|
|
21
|
+
# Expose port
|
|
22
|
+
EXPOSE 8080
|
|
23
|
+
|
|
24
|
+
# Health check
|
|
25
|
+
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
|
|
26
|
+
CMD wget --no-verbose --tries=1 --spider http://localhost:8080/health || exit 1
|
|
27
|
+
|
|
28
|
+
# Start the application
|
|
29
|
+
CMD ["npx", "serve", "-s", "dist", "-l", "8080", "--cors"]
|