Skip to content

Commit

Permalink
fix: pnpm and docker fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
SamTolmay committed Apr 14, 2023
1 parent 7e9549d commit a35c0b7
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 5 deletions.
1 change: 0 additions & 1 deletion .npmrc
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
strict-peer-dependencies=false
auto-install-peers=true
8 changes: 5 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ ENV LOWDEFY_BUILD_OUTPUT_STANDALONE 1
RUN corepack enable

# TODO: Change config-directory (./app) as appropriate here
RUN pnpx lowdefy@4 build --config-directory ./app --log-level=debug
RUN pnpx lowdefy@rc build --config-directory ./app --log-level=debug

RUN pnpm --filter=@lowdefy/server --prod deploy ./deploy

FROM node:18-alpine AS runner

Expand All @@ -23,11 +25,11 @@ RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 lowdefy

# TODO: Change from-directory (/lowdefy/app/.lowdefy/server/public) as appropriate here
COPY --from=builder /lowdefy/app/.lowdefy/server/public ./public
COPY --from=builder --chown=lowdefy:nodejs /lowdefy/app/.lowdefy/server/public ./public
# TODO: Change from-directory (/lowdefy/app/.lowdefy/server/.next/standalone) as appropriate here
COPY --from=builder --chown=lowdefy:nodejs /lowdefy/app/.lowdefy/server/.next/standalone ./

USER lowdefy
COPY --from=builder --chown=lowdefy:nodejs /lowdefy/deploy/node_modules ./node_modules

EXPOSE 3000

Expand Down
7 changes: 7 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: "3.9"
services:
lowdefy:
build: .
ports:
- "3000:3000"
env_file: ./app/.env
2 changes: 1 addition & 1 deletion pnpm-workspace.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
packages:
- 'app/*'
- '*'
- 'plugins/*'
- 'app/.lowdefy/*'

0 comments on commit a35c0b7

Please sign in to comment.