Deploy Django for the first time fails on build

-----  Dockerfile:20 ------------------- 18 | ENV NIXPACKS_PATH /opt/venv/bin:$NIXPACKS_PATH 19 | COPY . /app/. 20 | >>> RUN --mount=type=cache,id=s/996db621-e3ad-4d5f-97e9-7865696cc383-/root/cache/pip,target=/root/.cache/pip python -m venv --copies /opt/venv && . /opt/venv/bin/activate && pip install -r requirements.txt 21 | 22 | ------------------- ERROR: failed to solve: process "/bin/bash -ol pipefail -c python -m venv --copies /opt/venv && . /opt/venv/bin/activate && pip install -r requirements.txt" did not complete successfully: exit code: 1  Error: Docker build failed
12 Replies
Percy
Percy17mo ago
Project ID: 996db621-e3ad-4d5f-97e9-7865696cc383
MantisInABox
MantisInABox17mo ago
Can you share your build logs? And if possible, also your repo
Brody
Brody17mo ago
full build logs please
roei__levy
roei__levyOP17mo ago
GitHub
GitHub - RoeiLevy/MP3-to-Spotify-Back
Contribute to RoeiLevy/MP3-to-Spotify-Back development by creating an account on GitHub.
MantisInABox
MantisInABox17mo ago
One issue I see already is in your start command in railway.json, you are referencing mysite.wsgi it should be spotify_back.wsgi
roei__levy
roei__levyOP17mo ago
roei__levy
roei__levyOP17mo ago
pushing and checking now didn't work 😦
MantisInABox
MantisInABox17mo ago
It also looks like it is failing at the install of the mysqlclient package in your requirements.txt
roei__levy
roei__levyOP17mo ago
any idea why?
MantisInABox
MantisInABox17mo ago
I don’t usually use MySQL, so I wouldn’t be able to say for sure
Brody
Brody17mo ago
maybe adding the mysql nix package will help? save this as a nixpacks.toml file in your project
[phases.setup]
nixPkgs = ["...", "mysql80"]
[phases.setup]
nixPkgs = ["...", "mysql80"]
Want results from more Discord servers?
Add your server