zuehue commited on
Commit
a97e432
·
verified ·
1 Parent(s): 35a3994

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +13 -4
Dockerfile CHANGED
@@ -2,11 +2,20 @@
2
  FROM alpine:latest
3
 
4
  # Set environment variables for the bot token and chat ID
5
- ENV BOT_TOKEN=6860068358:AAGkgd5YuUv7bFz_clJ1unq_sEt6UjMuZG4
6
- ENV CHAT_ID=5808621911
7
 
8
  # Install curl
9
  RUN apk --no-cache add curl
10
 
11
- # Run the curl command using shell form
12
- CMD sh -c 'curl -s -X POST "https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" -d "chat_id=${CHAT_ID}" -d "text=Hello"'
 
 
 
 
 
 
 
 
 
 
2
  FROM alpine:latest
3
 
4
  # Set environment variables for the bot token and chat ID
5
+ ENV BOT_TOKEN=YOUR_BOT_TOKEN
6
+ ENV CHAT_ID=YOUR_CHAT_ID
7
 
8
  # Install curl
9
  RUN apk --no-cache add curl
10
 
11
+ # Set the working directory in the container
12
+ WORKDIR /app
13
+
14
+ # Copy the shell script into the container
15
+ COPY send_message.sh .
16
+
17
+ # Make the shell script executable
18
+ RUN chmod +x send_message.sh
19
+
20
+ # Run the shell script
21
+ CMD ["./send_message.sh"]