mirror of
https://github.com/hexastack/hexabot
synced 2025-01-22 10:35:37 +00:00
fix: draft-add ui development target
This commit is contained in:
parent
d47deeb899
commit
27dc278e2c
@ -41,7 +41,17 @@ services:
|
||||
build:
|
||||
context: ../
|
||||
dockerfile: ./frontend/Dockerfile
|
||||
target: development
|
||||
pull_policy: build
|
||||
environment:
|
||||
- NODE_ENV=development
|
||||
- CHOKIDAR_USEPOLLING=true
|
||||
- WATCHPACK_POLLING=true
|
||||
volumes:
|
||||
- ../frontend/src:/app/src
|
||||
- ../frontend/src/components:/app/src/components
|
||||
ports:
|
||||
- 8081:8081
|
||||
|
||||
widget:
|
||||
build:
|
||||
|
@ -73,3 +73,25 @@ ENV PORT 8080
|
||||
# server.js is created by next build from the standalone output
|
||||
# https://nextjs.org/docs/pages/api-reference/next-config-js/output
|
||||
CMD HOSTNAME="0.0.0.0" node server.js
|
||||
|
||||
FROM base AS development
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY --from=deps /app/node_modules ./node_modules
|
||||
COPY --from=deps /app/package.json ./package.json
|
||||
COPY --from=deps /app/package-lock.json ./package-lock.json
|
||||
COPY ./widget ./widget
|
||||
COPY ./frontend ./frontend
|
||||
COPY --from=deps /app/widget/node_modules ./widget/node_modules
|
||||
COPY --from=deps /app/frontend/node_modules ./frontend/node_modules
|
||||
|
||||
ENV NODE_ENV=development
|
||||
ENV CHOKIDAR_USEPOLLING=true
|
||||
ENV WATCHPACK_POLLING=true
|
||||
|
||||
EXPOSE 8081
|
||||
|
||||
WORKDIR /app/frontend
|
||||
|
||||
CMD ["npm", "run", "dev"]
|
@ -10,9 +10,15 @@ const nextConfig = withTM(["hexabot-widget"])({
|
||||
},
|
||||
];
|
||||
},
|
||||
webpack(config, _options) {
|
||||
return config;
|
||||
},
|
||||
webpack: (config => {
|
||||
config.watchOptions = {
|
||||
poll: 1000,
|
||||
aggregateTimeout: 300,
|
||||
// ignored: ['**/node_modules']
|
||||
}
|
||||
|
||||
return config
|
||||
}),
|
||||
publicRuntimeConfig: {
|
||||
lang: {
|
||||
default: "en",
|
||||
|
Loading…
Reference in New Issue
Block a user