• Jobs
  • Bootcamp
  • About Us
  • For professionals
    • Home
    • Jobs
    • Courses and challenges
    • Questions
    • Teachers
    • Bootcamp
  • For business
    • Home
    • Post job
    • Our process
    • Pricing
    • Assessments
    • Payroll
    • Blog
    • Sales
    • Salary Calculator

0

152
Views
Django file upload as different user

I have a Django application running on an mod_wsgi (embedded mode) Apache instance inside a Docker container. This container shares a volume (media/) with the host.

When a user uploads a file, it is stored in the media/<file> directory. The issue is that the file owner and group are both root, and I need write access to these for a particular user (tech) and/or group (tech-group).

I'm assuming it is happening because python is running as root in the container(?). Is there a way to instead have it run as tech? Or somehow tell Django to write files as a particular user/group?

over 1 year ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post job Pricing Our process Sales
Legal
Terms and conditions Privacy policy
© 2023 PeakU Inc. All Rights Reserved.