Project

Profile

Help

Issue #7109

Changing MEDIA_ROOT does not propagate to STATIC_ROOT etc

Added by kossusukka over 1 year ago. Updated 11 months ago.

Status:
CLOSED - DUPLICATE
Priority:
Normal
Assignee:
-
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
CentOS 7
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Quarter:

Description

Pulpcore: 3.4.1

Set MEDIA_ROOT = "/opt/pulp/data" in /etc/pulp/settings.py and create corresponding directories. /var/lib/pulp directory does not exist and is not supposed to (all data deployed in /opt/pulp)

Running "pulpcore-manager collectstatic" fails due to: PermissionError: [Errno 13] Permission denied: '/var/lib/pulp'

By editing MEDIA_ROOT directly inside venv-dir/lib64/python3.6/site-packages/pulpcore/app/settings.py everything works ok. Just user config (/etc/pulp/settings.py) are unable to change mediaroot.

This is due to os.path.join(MEDIA_ROOT, xxxxxxx -calls in default settings.py which are executed before loading dynamic/user config. Paths should be (re?)generated after loading user config.

This applies to STATIC_ROOT, FILE_UPLOAD_TEMP_DIR, CHUNKED_UPLOAD_DIR and possibly other paths which are defined by using MEDIA_ROOT before loading user defined config.


Related issues

Is duplicate of Pulp - Task #7178: Recommended installation layoutCLOSED - CURRENTRELEASE

<a title="Actions" class="icon-only icon-actions js-contextmenu" href="#">Actions</a>

History

#1 Updated by fao89 over 1 year ago

  • Triaged changed from No to Yes

#2 Updated by dkliban@redhat.com 11 months ago

  • Related to Task #7178: Recommended installation layout added

#3 Updated by dkliban@redhat.com 11 months ago

  • Related to deleted (Task #7178: Recommended installation layout)

#4 Updated by dkliban@redhat.com 11 months ago

  • Is duplicate of Task #7178: Recommended installation layout added

#5 Updated by dkliban@redhat.com 11 months ago

  • Status changed from NEW to CLOSED - DUPLICATE

Closing in favor of #7178 which will be fixed in 3.10. Thank you for reporting this issue.

Please register to edit this issue

Also available in: Atom PDF