mirror of
https://github.com/FranP-code/Open-Telegram-to-Notion-Backend.git
synced 2025-10-12 23:52:54 +00:00
creating docker
This commit is contained in:
2
.dockerignore
Normal file
2
.dockerignore
Normal file
@@ -0,0 +1,2 @@
|
||||
node_modules
|
||||
.env
|
||||
17
Dockerfile
Normal file
17
Dockerfile
Normal file
@@ -0,0 +1,17 @@
|
||||
FROM alpine:latest
|
||||
ARG NOTION_INTEGRATION_ID
|
||||
ARG NOTION_INTEGRATION_SECRET
|
||||
ARG PORT
|
||||
ARG NODE_ENV
|
||||
|
||||
RUN apk add --update nodejs npm
|
||||
RUN npm install --global yarn
|
||||
|
||||
COPY [".", "/usr/src"]
|
||||
WORKDIR "/usr/src"
|
||||
|
||||
RUN yarn
|
||||
|
||||
EXPOSE ${PORT}
|
||||
|
||||
CMD if [ ${NODE_ENV} = "development" ] ; then yarn run dev ; else yarn run start PORT=${PORT}; fi
|
||||
12
docker-compose.yml
Normal file
12
docker-compose.yml
Normal file
@@ -0,0 +1,12 @@
|
||||
version: "3.8"
|
||||
|
||||
services:
|
||||
backend:
|
||||
build: .
|
||||
ports:
|
||||
- "${PORT}:${PORT}"
|
||||
environment:
|
||||
- NOTION_INTEGRATION_ID=${NOTION_INTEGRATION_ID}
|
||||
- NOTION_INTEGRATION_SECRET=${NOTION_INTEGRATION_SECRET}
|
||||
- PORT=${PORT}
|
||||
- NODE_ENV=${NODE_ENV}
|
||||
Reference in New Issue
Block a user