Skip to content

Commit

Permalink
Add optimized Dockerfile and a new .dockerignore file (#68)
Browse files Browse the repository at this point in the history
* Create new Dockerfile to build and deploy app panel v2.1

* Optimize dockerfile

* Add new dockerignore file
  • Loading branch information
sysxtreme authored Aug 7, 2024
1 parent 2a95d91 commit 57e847e
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.DS_Store
dist/electron/*
dist/web/*
build/*
dist/*
!build/icons
node_modules/
npm-debug.log
npm-debug.log.*
thumbs.db
!.gitkeep
16 changes: 16 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
FROM node:8 AS build

WORKDIR /app

COPY . /app

RUN npm install && \
npm run build:web

FROM nginx:alpine

COPY --from=build --chown=nginx:nginx /app/dist/web /usr/share/nginx/html

EXPOSE 80

CMD ["nginx", "-g", "daemon off;"]

0 comments on commit 57e847e

Please sign in to comment.