Closed ihsaan-ullah closed 4 months ago
We should document the following
pyproject.toml
docker build --no-cache -f Dockerfile -t codabench-django:latest ./
docker build --no-cache -f Dockerfile -t codabench-site_worker:latest ./
NOTE: every time you build these containers, a fresh poetry.lock
file is generated in the container which is then used to install packages.
I get the following error after running docker compose up -d
:
=> CANCELED [codabench-compute_worker 2/9] RUN apt-get update && curl -fsSL https://get.docker.com | sh 41.1s
=> [codabench-flower 1/10] FROM docker.io/library/python:3.9-alpine@sha256:3beee521e2eec6a3a9ba0c2fdac1bf30969e7f275e379f5b0dd8b45b25f50955 0.0s
=> => resolve docker.io/library/python:3.9-alpine@sha256:3beee521e2eec6a3a9ba0c2fdac1bf30969e7f275e379f5b0dd8b45b25f50955 0.0s
=> CACHED [codabench-flower 2/10] RUN apk add --no-cache ca-certificates && update-ca-certificates curl 0.0s
=> CACHED [codabench-flower 3/10] RUN apk add curl 0.0s
=> ERROR [codabench-flower 4/10] RUN curl -sSL https://install.python-poetry.org | python3 - 40.5s
------
> [codabench-flower 4/10] RUN curl -sSL https://install.python-poetry.org | python3 -:
#0 40.37 Retrieving Poetry metadata
#0 40.37
#0 40.37 # Welcome to Poetry!
#0 40.37
#0 40.37 This will download and install the latest version of Poetry,
#0 40.37 a dependency and package manager for Python.
#0 40.37
#0 40.37 It will add the `poetry` command to Poetry's bin directory, located at:
#0 40.37
#0 40.37 /root/.local/bin
#0 40.37
#0 40.37 You can uninstall at any time by executing this script with the --uninstall option,
#0 40.37 and these changes will be reverted.
#0 40.37
#0 40.37 Installing Poetry (1.8.3)
#0 40.37 Installing Poetry (1.8.3): Creating environment
#0 40.37 Installing Poetry (1.8.3): Installing Poetry
#0 40.37 Installing Poetry (1.8.3): An error occurred. Removing partial environment.
#0 40.37 Poetry installation failed.
#0 40.37 See /poetry-installer-error-8ei1b6ej.log for error logs.
------
failed to solve: executor failed running [/bin/sh -c curl -sSL https://install.python-poetry.org | python3 -]: exit code: 1
looks like this is a problem from flower
. You need this dockerfile: https://github.com/codalab/codabench/pull/1520
looks like this is a problem from
flower
. You need this dockerfile: #1520
Oh yeah I did not realize the order of the PR. Thanks.
Working fine!
@ mention of reviewers
@Didayolo @bbearce
Benjamin I deleted the lock file because there was no way to generate the file. Docker build was failing with any change in the toml file.
A brief description of the purpose of the changes contained in this PR.
poetry.lock
file because when we make changes to package versions inpyproject.toml
we need to regenerate itpyproject.toml
updated python version to 3.9 to fix the inconsistency with dockerfile and bpython version to fix shell_plus errorDockerfile
removed copypoetry.lock
command and added poetry lock command to generate lock fileIssues this PR resolves
1537
1530
A checklist for hand testing
docker-compose exec django ./manage.py shell_plus
without any errorChecklist