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

Added logic to build and push dockerimage for multiple architectures #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all 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
14 changes: 13 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,23 @@
FROM python:3.11-slim

# Set working directory for copying, etc
WORKDIR /app

# Copy over requirements
COPY requirements.txt /app
RUN pip install -r requirements.txt

# Install dependencies
RUN apt-get update \
&& apt-get install -y build-essential \
&& pip install -r requirements.txt \
&& pip cache purge \
&& apt-get purge -y --auto-remove build-essential \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

# Copy over server script
COPY server.py /app

# Run application
EXPOSE 8675
CMD ["python", "/app/server.py"]
1 change: 1 addition & 0 deletions build_and_push.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7 -t stevenewald/raccoon-proxy:latest . --push
2 changes: 1 addition & 1 deletion server.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
PORT = "8675"

# Client settings
REMOTE_URL = "wss://websocket-echo.com"
REMOTE_URL = "wss://ws-feed.exchange.coinbase.com"


log = logging.getLogger("main")
Expand Down