Skip to content

Commit 480b8af

Browse files
docker: add docker image and add release action
1 parent d6a9b88 commit 480b8af

File tree

3 files changed

+7
-14
lines changed

3 files changed

+7
-14
lines changed

.env.local

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
# NEXT_PUBLIC_REST_URL=http://localhost:7001
2-
NEXT_NODE_ID=<node id>
3-
NEXT_ADDR=<ip>:<port>
4-
NEXT_RUNE=<>
1+
NEXT_NODE_ID=03e2408a49f07d2f4083a47344138ef89e7617e63919202c92aa8d49b574a560ae
2+
NEXT_ADDR=178.128.84.51:9735
3+
NEXT_RUNE=X-njDeJPQZdY6uUtAhqVL_WNcb8T1XZyBu1oUyLanus9NSZtZXRob2RebGlzdHxtZXRob2ReZ2V0fG1ldGhvZD1kZWNvZGUmbWV0aG9kL2xpc3RkYXRhc3RvcmU=
54
NEXT_LAMBDA=http://ec2-52-55-124-1.compute-1.amazonaws.com:9002
65
NEXT_LNMETRICS_URL=https://api.lnmetrics.info/query

Dockerfile

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# Install dependencies only when needed
2-
FROM node:alpine AS deps
2+
FROM node:slim AS deps
33
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.
4-
RUN apk add --no-cache libc6-compat
54
WORKDIR /app
65
COPY package.json ./
76
RUN npm install
@@ -14,23 +13,18 @@ COPY --from=deps /app/node_modules ./node_modules
1413
RUN npm run build
1514

1615
# Production image, copy all the files and run next
17-
FROM node:alpine AS runner
16+
FROM node:slim AS runner
1817
WORKDIR /app
1918

2019
ENV NODE_ENV production
2120

22-
RUN addgroup -g 1001 -S nodejs
23-
RUN adduser -S nextjs -u 1001
24-
2521
# You only need to copy next.config.js if you are NOT using the default configuration
2622
# COPY --from=builder /app/next.config.js ./
2723
COPY --from=builder /app/public ./public
28-
COPY --from=builder --chown=nextjs:nodejs /app/.next ./.next
24+
COPY --from=builder /app/.next ./.next
2925
COPY --from=builder /app/node_modules ./node_modules
3026
COPY --from=builder /app/package.json ./package.json
3127

32-
USER nextjs
33-
3428
EXPOSE 3000
3529

3630
# Next.js collects completely anonymous telemetry data about general usage.

docker-compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ services:
55
build: .
66
restart: on-failure
77
ports:
8-
- "3000:8080"
8+
- "8080:3000"
99
environment:
1010
# - NEXT_PUBLIC_REST_URL=http://127.0.0.1:8080/rest
1111
- NEXT_NODE_ID=<node id>

0 commit comments

Comments
 (0)