-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
12 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,16 @@ | ||
FROM python:3.9-slim | ||
|
||
# Install Redis | ||
RUN apt-get update && apt-get install -y redis-server && apt-get clean && rm -rf /var/lib/apt/lists/* | ||
FROM python:3.10-alpine | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy requirements.txt if you have one | ||
COPY requirements.txt . | ||
|
||
# Install dependencies | ||
RUN pip install --no-cache-dir -r requirements.txt | ||
|
||
# If you don't have a requirements.txt, you can install directly | ||
# RUN pip install --no-cache-dir python-telegram-bot>=20.0 | ||
# Upgrade pip and setuptools, then install dependencies | ||
RUN pip install --upgrade pip setuptools && pip install --no-cache-dir -r requirements.txt | ||
|
||
# Copy the rest of your application code | ||
COPY . . | ||
COPY bot.py . | ||
|
||
# Start Redis and run the bot | ||
CMD ["sh", "-c", "redis-server --daemonize yes && python bot.py"] | ||
# Start the bot | ||
CMD ["python", "bot.py"] |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters