-
Notifications
You must be signed in to change notification settings - Fork 94
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
restructure and update arm build files
- Loading branch information
1 parent
3c9dd53
commit 0e932a8
Showing
6 changed files
with
29 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,29 @@ | ||
# Use a base image compatible with ARMv6 architecture | ||
FROM arm32v6/node:14-alpine | ||
|
||
# Install necessary build dependencies | ||
RUN apk add --no-cache make gcc g++ python3 linux-headers udev tzdata git | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy package.json and package-lock.json | ||
COPY package*.json ./ | ||
|
||
# Install dependencies | ||
RUN npm install | ||
# Install dependencies (both development and production) | ||
RUN npm ci | ||
|
||
# Copy the rest of the application | ||
COPY . . | ||
|
||
# Build the application | ||
RUN npm run build | ||
|
||
# Expose the port | ||
# Set environment variables | ||
ENV NODE_ENV=production | ||
|
||
# Expose the port (if applicable) | ||
EXPOSE 4200 | ||
|
||
# Command to run the application | ||
CMD ["npm", "start"] | ||
CMD ["node", "dist/app.js"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,29 @@ | ||
# Use a base image compatible with ARMv7 architecture | ||
FROM arm32v7/node:14-alpine | ||
|
||
# Install necessary build dependencies | ||
RUN apk add --no-cache make gcc g++ python3 linux-headers udev tzdata git | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy package.json and package-lock.json | ||
COPY package*.json ./ | ||
|
||
# Install dependencies | ||
RUN npm install | ||
# Install dependencies (both development and production) | ||
RUN npm ci | ||
|
||
# Copy the rest of the application | ||
COPY . . | ||
|
||
# Build the application | ||
RUN npm run build | ||
|
||
# Expose the port | ||
# Set environment variables | ||
ENV NODE_ENV=production | ||
|
||
# Expose the port (if applicable) | ||
EXPOSE 4200 | ||
|
||
# Command to run the application | ||
CMD ["npm", "start"] | ||
CMD ["node", "dist/app.js"] |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters