Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DLPX-89539 CIS: postgres user account settings #777

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions live-build/config/hooks/vm-artifacts/90-raw-disk-image.binary
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,19 @@ cat <<-EOF >"$DIRECTORY/etc/fstab"
rpool/crashdump /var/crash zfs defaults,x-systemd.before=zfs-import-cache.service,x-systemd.before=kdump-tools.service 0 0
EOF

LOGIN_DEFS_FILE="$DIRECTORY/etc/login.defs"

#
# Update UMASK value in /etc/login.defs to 027 to ensure files
# created by users have the correct permissions
#

if grep -q "^UMASK" "$LOGIN_DEFS_FILE"; then
sed -i 's/^UMASK\s\+[0-9]\+/UMASK 027/' "$LOGIN_DEFS_FILE"
else
echo "UMASK 027" >>"$LOGIN_DEFS_FILE"
fi

#
# Now we need to install the bootloader. In order to do that, we'll chroot
# into the newly populated root filesystem, so that we use the grub-install
Expand Down
13 changes: 13 additions & 0 deletions upgrade/upgrade-scripts/upgrade-container
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,19 @@ function create_upgrade_container() {
rpool/crashdump /var/crash zfs defaults,x-systemd.before=zfs-import-cache.service,x-systemd.before=kdump-tools.service 0 0
EOF

LOGIN_DEFS_FILE="$DIRECTORY/etc/login.defs"

#
# Update UMASK value in /etc/login.defs to 027 to ensure files
# created by users have the correct permissions
#

if grep -q "^UMASK" "$LOGIN_DEFS_FILE"; then
sed -i 's/^UMASK\s\+[0-9]\+/UMASK 027/' "$LOGIN_DEFS_FILE"
else
echo "UMASK 027" >>"$LOGIN_DEFS_FILE"
fi

#
# DLPX-75089 - Since older versions of Delphix did not properly
# disable the NFS services within the upgrade container, we have
Expand Down