File tree Expand file tree Collapse file tree 4 files changed +15
-5
lines changed
Expand file tree Collapse file tree 4 files changed +15
-5
lines changed Original file line number Diff line number Diff line change @@ -25,5 +25,5 @@ def _get_rotate_dest_filename(source):
2525 os .path .basename (source )
2626 ]
2727 filename = os .path .join (* path )
28- os .makedirs (os .path .dirname (filename ), exist_ok = True )
28+ os .makedirs (os .path .dirname (filename ), 0o700 , exist_ok = True )
2929 return filename
Original file line number Diff line number Diff line change 122122SYSLOG_ENABLE = CONFIG .SYSLOG_ENABLE
123123
124124if not os .path .isdir (LOG_DIR ):
125- os .makedirs (LOG_DIR , mode = 0o755 )
125+ os .makedirs (LOG_DIR , mode = 0o700 , exist_ok = True )
Original file line number Diff line number Diff line change 11#! /bin/bash
22
3- mkdir -p /opt/maxkb/logs
4- mkdir -p /opt/maxkb/local
3+ if [ ! -d /opt/maxkb/logs ]; then
4+ mkdir -p /opt/maxkb/logs
5+ chmod 700 /opt/maxkb/logs
6+ fi
7+ if [ ! -d /opt/maxkb/local ]; then
8+ mkdir -p /opt/maxkb/local
9+ chmod 700 /opt/maxkb/local
10+ fi
511mkdir -p /opt/maxkb/python-packages
612
713rm -f /opt/maxkb-app/tmp/* .pid
Original file line number Diff line number Diff line change 11#! /bin/bash
22
3- mkdir -p /opt/maxkb/data/redis
3+ if [ ! -d /opt/maxkb/data/redis ]; then
4+ mkdir -p /opt/maxkb/data/redis
5+ chmod 700 /opt/maxkb/data/redis
6+ fi
47mkdir -p /opt/maxkb/logs
58
69if [ ! -f /opt/maxkb/conf/redis.conf ]; then
710 mkdir -p /opt/maxkb/conf
811 touch /opt/maxkb/conf/redis.conf
12+ chmod 700 /opt/maxkb/conf/redis.conf
913 cat << EOF > /opt/maxkb/conf/redis.conf
1014bind 0.0.0.0
1115port 6379
You can’t perform that action at this time.
0 commit comments