Skip to content

Commit

Permalink
fix netplan file permissions.
Browse files Browse the repository at this point in the history
  • Loading branch information
HappyBasher committed Feb 19, 2024
1 parent cc60379 commit 8332294
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/setup.d/z_final.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@
#
# final tasks
# thomas@linuxmuster.net
# 20220105
# 20240219
#

import configparser
import constants
import glob
import os
import re
import sys
Expand All @@ -30,6 +31,10 @@
printScript(' Failed!', '', True, True, False, len(msg))
sys.exit(1)

# fix netplan file permissions
for file in glob.glob('/etc/netplan/*.yaml*'):
os.chmod(file, 0o600)

# restart apparmor service
msg = 'Restarting apparmor service '
printScript(msg, '', False, False, True)
Expand Down

0 comments on commit 8332294

Please sign in to comment.