Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Titouan Soulard
slapos.core
Commits
6a2b58f5
Commit
6a2b58f5
authored
6 years ago
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't spawn too many subprocesses in chownDirectory()
parent
062aebea
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
slapos/util.py
slapos/util.py
+2
-2
No files found.
slapos/util.py
View file @
6a2b58f5
...
...
@@ -53,10 +53,10 @@ def chownDirectory(path, uid, gid):
if
os
.
getuid
()
!=
0
:
# we are probably inside of a webrunner
return
# find /opt/slapgrid -not -user 1000 -exec chown slapsoft:slapsoft {}
\;
# find /opt/slapgrid -not -user 1000 -exec chown slapsoft:slapsoft {}
+
subprocess
.
check_call
([
'/usr/bin/find'
,
path
,
'-not'
,
'-user'
,
str
(
uid
),
'-exec'
,
'/bin/chown'
,
'%s:%s'
%
(
uid
,
gid
),
'{}'
,
'
;
'
'/bin/chown'
,
'%s:%s'
%
(
uid
,
gid
),
'{}'
,
'
+
'
])
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment