Skip to content

Commit 44eb7a1

Browse files
committed
fix errors
1 parent 1ac1435 commit 44eb7a1

2 files changed

Lines changed: 6 additions & 7 deletions

File tree

.github/workflows/docker-image.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,12 @@ jobs:
1717
- name: Docker Login
1818
run: docker login -u ${{ secrets.REGISTRY_USERNAME }} -p ${{ secrets.REGISTRY_PASSWORD }}
1919

20+
- name: Docker Builder Buidx
21+
run: docker buildx create --use --platform=linux/arm64,linux/amd64 --name multi-platform-builder
2022

2123
- name: Docker Build
22-
run: docker build . -t index.docker.io/maxiplux/fastapidevops-auth
24+
run: docker buildx build --platform linux/amd64,linux/arm64 . maxiplux/fastapidevops-auth:latest
2325
- name: Docker Push
2426
run: docker push index.docker.io/maxiplux/fastapidevops-auth
27+
28+

Dockerfile

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ FROM python:${PYTHON_VERSION}-slim as base
1010
# Prevents Python from writing pyc files.
1111
ENV PYTHONDONTWRITEBYTECODE=1
1212
# Set default environment variables
13-
ENV DB_USERNAME=postgres
14-
ENV DB_PASSWORD=postgres
15-
ENV DB_HOST=LOCALHOST
16-
ENV DB_NAME=postgres
1713

1814
# Keeps Python from buffering stdout and stderr to avoid situations where
1915
# the application crashes without emitting any logs due to buffering.
@@ -51,5 +47,4 @@ COPY . .
5147
EXPOSE 80
5248

5349
# Run the application.
54-
#CMD gunicorn '.venv.lib.python3.12.site-packages.fastapi.middleware.wsgi' --bind=0.0.0.0:80
55-
CMD uvicorn main:app --host 0.0.0.0 --port 80
50+
CMD uvicorn main:app --reload --host 0.0.0.0 --port 80 --reload --reload-dir /app

0 commit comments

Comments
 (0)