Skip to content
This repository has been archived by the owner on Sep 19, 2024. It is now read-only.

Commit

Permalink
Merge pull request #7 from bemble/fix_docker_start
Browse files Browse the repository at this point in the history
Fix docker start
  • Loading branch information
bemble authored May 9, 2024
2 parents 1d4d3a7 + 2cd4993 commit 81f4bf8
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@ jobs:
uses: actions/checkout@v2

- name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3

- name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ github.repository_owner }}
password: ${{ secrets.HUB_TOKEN }}

- name: Log in to ghcr.io
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
Expand All @@ -51,7 +51,7 @@ jobs:
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64
Expand Down
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ COPY --from=front-builder /app/public /app/public

# copy server files
COPY ./server /app/server
RUN chmod +x /app/server/entrypoint.sh

WORKDIR /app/server
RUN pip install -r requirements.txt
CMD ["python", "-m", "holerr"]
ENTRYPOINT ["/app/server/entrypoint.sh"]

EXPOSE 8765
8 changes: 8 additions & 0 deletions server/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/sh

if [ -d ".venv" ]
then
source ".venv/bin/activate"
fi
alembic upgrade head
python -m holerr

0 comments on commit 81f4bf8

Please sign in to comment.