forked from evgeny-nadymov/telegram-react
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (20 loc) · 666 Bytes
/
Copy pathDockerfile
File metadata and controls
27 lines (20 loc) · 666 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
FROM node:18-slim
WORKDIR /app/
# Set NODE_OPTIONS to allow legacy OpenSSL provider
ENV NODE_OPTIONS=--openssl-legacy-provider
# Copy package files and install dependencies
COPY package.json ./
RUN npm install --legacy-peer-deps
# Copy TDWeb files to public directory
RUN mkdir -p public/
COPY . .
RUN cp -v node_modules/tdweb/dist/* public/
# Set Telegram API environment variables (can be overridden at runtime)
ARG TELEGRAM_API_ID
ENV REACT_APP_TELEGRAM_API_ID=${TELEGRAM_API_ID}
ARG TELEGRAM_API_HASH
ENV REACT_APP_TELEGRAM_API_HASH=${TELEGRAM_API_HASH}
# Expose the development server port
EXPOSE 3000
# Start the development server
CMD ["npm", "start"]