build: sandbox权限限制禁止向/tmp写入
This commit is contained in:
parent
677ce46b49
commit
2653c75f21
@ -62,7 +62,7 @@ RUN chmod 755 /opt/maxkb/app/installer/run-maxkb.sh && \
|
|||||||
cp -f /opt/maxkb/app/installer/init.sql /docker-entrypoint-initdb.d && \
|
cp -f /opt/maxkb/app/installer/init.sql /docker-entrypoint-initdb.d && \
|
||||||
mkdir -p /opt/maxkb/app/sandbox/python-packages && \
|
mkdir -p /opt/maxkb/app/sandbox/python-packages && \
|
||||||
find /opt/maxkb/app -mindepth 1 -not -name 'sandbox' -exec chmod 700 {} + && \
|
find /opt/maxkb/app -mindepth 1 -not -name 'sandbox' -exec chmod 700 {} + && \
|
||||||
chmod 500 /opt/maxkb/app/sandbox && \
|
chmod 755 /tmp && \
|
||||||
useradd --no-create-home --home /opt/maxkb/app/sandbox --shell /bin/bash sandbox && \
|
useradd --no-create-home --home /opt/maxkb/app/sandbox --shell /bin/bash sandbox && \
|
||||||
chown sandbox:sandbox /opt/maxkb/app/sandbox
|
chown sandbox:sandbox /opt/maxkb/app/sandbox
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user