Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add containerization support #32

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Ignore common files generated during the build process
*.pyc
*.pyo
__pycache__/
*.egg-info/
*.egg
*.egg-info

# Ignore development environment files
*.env
*.log
.env
.venv/
.idea/
.vscode/
.cache/
.coverage
htmlcov/

# Ignore scripts
scripts/

# Ignore non-essential files and directories
CODE_OF_CONDUCT.md
CONTRIBUTING.md
LICENSE.txt
README.md
requirements-dev.txt
17 changes: 17 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# base image for python
FROM python:3.10-alpine3.16

danielsp45 marked this conversation as resolved.
Show resolved Hide resolved
# working directory
WORKDIR /app

# set the required dependencies
COPY requirements.txt requirements.txt

# install dependencies
RUN pip install -r requirements.txt

# copy the content of the local src directory to the working directory
COPY . .

# run the command to start the bot
CMD [ "python3", "-m", "bot"]
7 changes: 7 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: "3"

services:
gongo:
container_name: gongo
build: .
danielsp45 marked this conversation as resolved.
Show resolved Hide resolved
image: python:3.10-alpine3.16