coollabsio / coolify

An open-source & self-hostable Heroku / Netlify / Vercel alternative.
https://coolify.io
Apache License 2.0
31.93k stars 1.65k forks source link

[Bug]: libstdc++.so.6 ImportError in Django Container Shell on self-hosted Coolify #2285

Open brightkan opened 4 months ago

brightkan commented 4 months ago

Description

When running the /opt/venv/bin/python /app/manage.py <django_management_command> command in the container shell or scheduled tasks, it fails with an ImportError. This issue does not occur when running the same command via the UI, where it works as expected. The error indicates that libstdc++.so.6 cannot be found, suggesting it might not be installed or added to the container properly. The issue prevents any efforts to add custom Django management commands in Coolify Scheduled Tasks.

Minimal Reproduction (if possible, example repository)

  1. Deploy a stack using:
    • v4.0.0-beta.285
    • Django 4.2
    • Python 3.10
    • Nixpacks Access the container shell using the name provided in the UI, in my case, it is something like "u44cogw-132156335844". using docker exec -it <container_name> bash Run the command: /opt/venv/bin/python /app/manage.py <django_management_command> Observe the ImportError

Exception or Error

ImportError: libstdc++.so.6: cannot open shared object file: No such file or directory

Version

v4.0.0-beta.285

andrasbacsai commented 4 months ago

There will be a few fixes in the upcoming version for scheduled tasks that could potentially solve this.