File tree Expand file tree Collapse file tree 5 files changed +14
-10
lines changed
{{cookiecutter.project_slug}} Expand file tree Collapse file tree 5 files changed +14
-10
lines changed Original file line number Diff line number Diff line change 11#! /usr/bin/env bash
22set -e
33
4- hatch run production: python /app/app/tests_pre_start.py
4+ hatch run python /app/app/tests_pre_start.py
55
66bash ./scripts/test.sh " $@ "
Original file line number Diff line number Diff line change 11#! /usr/bin/env bash
22set -e
33
4- hatch run production: python /app/app/celeryworker_pre_start.py
5- hatch run production: celery -A app.worker worker -l info -Q main-queue -c 1
4+ hatch run python /app/app/celeryworker_pre_start.py
5+ hatch run celery -A app.worker worker -l info -Q main-queue -c 1
Original file line number Diff line number Diff line change @@ -80,8 +80,8 @@ services:
8080 frontend :
8181 volumes :
8282 # https://stackoverflow.com/a/32785014
83- - ./frontend:/app
84- - /app /node_modules
83+ - ./frontend:/frontend
84+ - node_modules:/frontend /node_modules
8585 build :
8686 context : ./frontend
8787 target : run-dev
@@ -91,6 +91,9 @@ services:
9191 - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.rule=PathPrefix(`/`)
9292 - traefik.http.services.${STACK_NAME?Variable not set}-frontend.loadbalancer.server.port=80
9393
94+ volumes :
95+ node_modules :
96+
9497networks :
9598 traefik-public :
9699 # For local dev, don't expect an external Traefik network
Original file line number Diff line number Diff line change 11FROM node:18.17.0 AS build
22ENV NODE_ENV=development NITRO_HOST=${NUXT_HOST:-0.0.0.0} NITRO_PORT=${NUXT_PORT:-3000} NUXT_TELEMETRY_DISABLED=1
3- COPY . /app
4- WORKDIR /app
3+ COPY . /frontend
4+ WORKDIR /frontend
55RUN yarn install --frozen-lockfile --network-timeout 100000 --non-interactive
66RUN yarn build --standalone
77EXPOSE ${NUXT_PORT}
@@ -33,7 +33,7 @@ ARG VEE_INT_VERSION=^4.7.3
3333ARG VEE_RULES_VERSION=^4.7.3
3434ARG QR_CODE_VERSION=^3.3.3
3535ENV NODE_ENV=production NITRO_HOST=${NUXT_HOST:-0.0.0.0} NITRO_PORT=${NUXT_PORT:-3000} NUXT_TELEMETRY_DISABLED=1
36- WORKDIR /app
36+ WORKDIR /frontend
3737RUN yarn add nuxt@${NUXT_VERSION} @nuxt/content@${NUXT_CONTENT_VERSION} tailwindcss@${TAILWINDCSS_VERSION} autoprefixer@${AUTOPREFIXER_VERSION} postcss@${POSTCSS_VERSION} @tailwindcss/aspect-ratio@${ASPECT_RATIO_VERSION} @tailwindcss/forms@${FORMS_VERSION} @tailwindcss/typography@${TYPOGRAPHY_VERSION} @headlessui/vue@${HEADLESSUI_VERSION} @heroicons/vue@${HEROICONS_VERSION} @pinia/nuxt@${PINIA_VERSION} @pinia-plugin-persistedstate/nuxt${PINIA_PERSISTED_VERSION} vee-validate@${VEE_VERSION} @vee-validate/i18n${VEE_INT_VERSION} @vee-validate/rules${VEE_RULES_VERSION} qrcode.vue${QR_CODE_VERSION}
3838COPY --from=build /app/.nuxt ./.nuxt
3939COPY --from=build /app/api ./api
@@ -53,4 +53,5 @@ COPY --from=build /app/app.vue ./
5353COPY --from=build /app/nuxt.config* ./
5454COPY --from=build /app/tailwind.config* ./
5555COPY --from=build /app/tsconfig.json ./
56- CMD ["node" , ".output/server/index.mjs" ]
56+ ENTRYPOINT [ "yarn" ]
57+ CMD [ "start" ]
Original file line number Diff line number Diff line change 44 "build" : " nuxt build" ,
55 "dev" : " nuxt dev" ,
66 "generate" : " nuxt generate" ,
7- "start" : " node .output/server/index.mjs " ,
7+ "start" : " nuxt start " ,
88 "preview" : " nuxt preview"
99 },
1010 "devDependencies" : {
You can’t perform that action at this time.
0 commit comments