Skip to content

Commit b5923e3

Browse files
committed
Change openshift example to use userdel/useradd instead of usermod
When using usermod (or useradd without -l), a sparse file is created for lastlog/faillog. The extents of the file scale with the UID, and Docker does not see the file as sparse, so it will try to generate a huge image without this patch. (See moby/moby#5419 for details) Signed-off-by: Burt Holzman <burt@fnal.gov>
1 parent 4c3fc63 commit b5923e3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

setup/kubernetes/openshift.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ spec:
161161
USER root
162162
163163
# As root, change the coder user id
164-
RUN usermod --uid=1000670000 coder
164+
RUN userdel coder && useradd -l -u 1000670000 coder && chown coder:coder /home/coder
165165
166166
# Go back to the user 'coder'
167167
USER coder

0 commit comments

Comments
 (0)