chore: add Dockerfile,and port flag

Signed-off-by: Hanif Dwy Putra S <hanifdwyputrasembiring@gmail.com>
This commit is contained in:
Hanif Dwy Putra S
2022-10-01 04:08:31 +00:00
parent 952fdac385
commit 59edecd350
2 changed files with 18 additions and 1 deletions

17
Dockerfile Normal file
View File

@@ -0,0 +1,17 @@
FROM node:current-alpine3.15
RUN apk update
# Prepare
RUN mkdir -p /home/tiktok-dl
COPY . /home/tiktok-dl
WORKDIR /home/tiktok-dl
# Build
RUN yarn install
RUN yarn build
# Expose port
EXPOSE 3000
CMD ["yarn", "start"]

View File

@@ -19,7 +19,7 @@
"dev": "next dev",
"lint": "next lint",
"format": "prettier . --write",
"start": "next start"
"start": "next start --port ${PORT-3000}"
},
"devDependencies": {
"@next/eslint-plugin-next": "12.2.4",