Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On Windows tutor dev start fails because of "Permission denied" #1034

Open
regisb opened this issue Apr 4, 2024 · 0 comments · May be fixed by #1074
Open

On Windows tutor dev start fails because of "Permission denied" #1034

regisb opened this issue Apr 4, 2024 · 0 comments · May be fixed by #1074
Assignees
Labels
bug Bugs will be investigated and fixed as quickly as possible.

Comments

@regisb
Copy link
Contributor

regisb commented Apr 4, 2024

Bug description

When running tutor dev commands on Windows, the all.log and tracking.log files are owned by root. But the user ID in the lms and cms containers is 1000. As a consequence, runserver commands fail to start.

This issue is caused by the fact that the permissions service sets the OPENEDX_USER_ID to "{{ HOST_USER_ID }}", which is 0:

services:
  permissions:
    environment:
      OPENEDX_USER_ID: "{{ HOST_USER_ID }}"

But the lms/cms containers run as user 1000:

x-openedx-job-service:
  &openedx-job-service
  ...
    args:
      # Note that we never build the openedx-dev image with root user ID, as it would simply fail.
      APP_USER_ID: "{{ HOST_USER_ID or 1000 }}"

To resolve the issue, we should update the permissions container to set OPENEDX_USER_ID: "{{ HOST_USER_ID or 1000 }}".

How to reproduce

On windows, run tutor dev start. The command will fail with the following error:

PermissionError: [Errno 13] Permission denied: '/openedx/data/logs/all.log'

Environment

Windows.

Additional context

See discussion here: https://discuss.openedx.org/t/tutor-dev-host-user-id-on-windows-10-causing-containers-to-exit-errno-13-permission-denied-openedx-data-logs-all-log/12328/3

@regisb regisb added the bug Bugs will be investigated and fixed as quickly as possible. label Apr 4, 2024
@Danyal-Faheem Danyal-Faheem self-assigned this Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bugs will be investigated and fixed as quickly as possible.
Projects
Status: In review
Development

Successfully merging a pull request may close this issue.

2 participants