gpt4free icon indicating copy to clipboard operation
gpt4free copied to clipboard

docker-composer throwing "Permission denied: '/home/seluser/.local/lib'"

Open tyler36 opened this issue 1 year ago • 10 comments

Bug description I'm trying to following the steup steps for Docker for Developers. After cloning the project, I run docker-compose build but get the following error:

 > [gpt4free 8/9] RUN pip install --upgrade pip && pip install -r requirements.txt:
0.427 Defaulting to user installation because normal site-packages is not writeable
0.453 Requirement already satisfied: pip in /usr/lib/python3/dist-packages (22.0.2)
0.588 Collecting pip
0.677   Downloading pip-23.3.1-py3-none-any.whl (2.1 MB)
0.737      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.1/2.1 MB 36.3 MB/s eta 0:00:00
0.750 Installing collected packages: pip
0.756 ERROR: Could not install packages due to an OSError: [Errno 13] Permission denied: '/home/seluser/.local/lib'
0.756 Check the permissions.

Environment

  • Docker Desktop
  • WSL Ubuntu
  • Japan

tyler36 avatar Dec 13 '23 01:12 tyler36

I changed the ID from the user to 1000. I forget to change the home. I fixed that.

hlohaus avatar Dec 13 '23 14:12 hlohaus

Thank you for the quick response.

I pulled the latest changes and was able to complete the build process. 🥳

When I run docker-compose up I get 2 persmission errors and it exists:

✔ Container gpt4free-gpt4free-1  Created                                                                                                      0.1s 
Attaching to gpt4free-1
gpt4free-1  | Creating directory /home/seluser/Downloads 
gpt4free-1  | Changing /home/seluser/Downloads ownership. /home/seluser/Downloads is owned by seluser 
gpt4free-1  | ERROR: no write access to download dir /home/seluser/Downloads. Please correct the permissions and restart.
gpt4free-1  | Traceback (most recent call last):
gpt4free-1  |   File "/usr/bin/supervisord", line 33, in <module>
gpt4free-1  |     sys.exit(load_entry_point('supervisor==4.2.1', 'console_scripts', 'supervisord')())
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/supervisord.py", line 361, in main
gpt4free-1  |     go(options)
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/supervisord.py", line 371, in go
gpt4free-1  |     d.main()
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/supervisord.py", line 72, in main
gpt4free-1  |     self.options.make_logger()
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/options.py", line 1470, in make_logger
gpt4free-1  |     loggers.handle_file(
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/loggers.py", line 417, in handle_file
gpt4free-1  |     handler = RotatingFileHandler(filename, 'a', maxbytes, backups)
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/loggers.py", line 213, in __init__
gpt4free-1  |     FileHandler.__init__(self, filename, mode)
gpt4free-1  |   File "/usr/lib/python3/dist-packages/supervisor/loggers.py", line 160, in __init__
gpt4free-1  |     self.stream = open(filename, mode)
gpt4free-1  | PermissionError: [Errno 13] Permission denied: '/var/log/supervisor/supervisord.log'
gpt4free-1 exited with code 1

tyler36 avatar Dec 14 '23 00:12 tyler36

same issue to me!

seth100 avatar Dec 14 '23 08:12 seth100

same issue to me!

ViVlVl avatar Dec 15 '23 14:12 ViVlVl

new changes fixed the issue for me, but now I cannot access the UI chat on http://localhost:8080/chat

seth100 avatar Dec 18 '23 10:12 seth100

Bumping this issue because it has been open for 7 days with no activity. Closing automatically in 7 days unless it becomes active again.

github-actions[bot] avatar Dec 26 '23 00:12 github-actions[bot]

Tried this again today with the latest version: g4f v-0.1.9.6 docker fix

I am able to access and use http://127.0.0.1:8080 chat UI. I also get a JSON API response when accessing http://localhost:1337/ , although I have no idea how to use the API.

tyler36 avatar Dec 26 '23 00:12 tyler36

Bumping this issue because it has been open for 7 days with no activity. Closing automatically in 7 days unless it becomes active again.

github-actions[bot] avatar Jan 03 '24 00:01 github-actions[bot]

Bumping this issue because it has been open for 7 days with no activity. Closing automatically in 7 days unless it becomes active again.

github-actions[bot] avatar Jan 14 '24 00:01 github-actions[bot]

Bumping this issue because it has been open for 7 days with no activity. Closing automatically in 7 days unless it becomes active again.

github-actions[bot] avatar Feb 10 '24 00:02 github-actions[bot]

Closing due to inactivity.

github-actions[bot] avatar Feb 24 '24 00:02 github-actions[bot]