chore: move /usr/etc to /etc per upstream rpm-ostree recommendation

This commit is contained in:
qoijjj
2024-08-08 15:48:30 -07:00
parent ed02255f57
commit 3fb96ece10
40 changed files with 20 additions and 24 deletions

View File

@@ -3,4 +3,4 @@
# Tell build process to exit if there are any errors. # Tell build process to exit if there are any errors.
set -oue pipefail set -oue pipefail
mkdir -p /usr/etc/xdg/autostart mkdir -p /etc/xdg/autostart

View File

@@ -3,4 +3,4 @@
# Tell build process to exit if there are any errors. # Tell build process to exit if there are any errors.
set -oue pipefail set -oue pipefail
echo "X-GNOME-Autostart-enabled=false" >> /usr/etc/xdg/autostart/sealertauto.desktop echo "X-GNOME-Autostart-enabled=false" >> /etc/xdg/autostart/sealertauto.desktop

View File

@@ -10,9 +10,9 @@ echo "
# https://github.com/containers/bubblewrap/security/advisories/GHSA-j2qp-rvxj-43vj # https://github.com/containers/bubblewrap/security/advisories/GHSA-j2qp-rvxj-43vj
user.max_user_namespaces = 0 user.max_user_namespaces = 0
" >> /usr/etc/sysctl.d/hardening.conf " >> /etc/sysctl.d/hardening.conf
mkdir -p /usr/etc/systemd/system/upower.service.d/ mkdir -p /etc/systemd/system/upower.service.d/
echo " echo "
@@ -20,10 +20,10 @@ echo "
# Namespaces # Namespaces
PrivateUsers=no PrivateUsers=no
" >> /usr/etc/systemd/system/upower.service.d/namespaces.conf " >> /etc/systemd/system/upower.service.d/namespaces.conf
mkdir -p /usr/etc/systemd/system/colord.service.d/ mkdir -p /etc/systemd/system/colord.service.d/
echo " echo "
@@ -31,7 +31,7 @@ echo "
# Namespaces # Namespaces
PrivateUsers=no PrivateUsers=no
" >> /usr/etc/systemd/system/colord.service.d/namespaces.conf " >> /etc/systemd/system/colord.service.d/namespaces.conf
chown root:root /usr/bin/bwrap chown root:root /usr/bin/bwrap
chmod u+s /usr/bin/bwrap chmod u+s /usr/bin/bwrap
@@ -62,4 +62,4 @@ semodule -i chrome_sandbox.pp
rm chrome_sandbox.te rm chrome_sandbox.te
rm chrome_sandbox.mod rm chrome_sandbox.mod
rm chrome_sandbox.pp rm chrome_sandbox.pp

View File

@@ -3,7 +3,7 @@
# Tell build process to exit if there are any errors. # Tell build process to exit if there are any errors.
set -oue pipefail set -oue pipefail
sed -i 's/insecureAcceptAnything/reject/' /usr/etc/containers/policy.json sed -i 's/insecureAcceptAnything/reject/' /etc/containers/policy.json
# Exception for build-container-installer to allow the ISO generation script to work # Exception for build-container-installer to allow the ISO generation script to work
@@ -32,4 +32,4 @@ yq -i -o=j '.transports.docker |=
} }
] ]
} }
+ .' /usr/etc/containers/policy.json + .' /etc/containers/policy.json

View File

@@ -8,4 +8,4 @@ echo "
HOMEBREW_NO_ANALYTICS=1 HOMEBREW_NO_ANALYTICS=1
" >> /usr/etc/environment " >> /etc/environment

View File

@@ -3,4 +3,4 @@
# Tell build process to exit if there are any errors. # Tell build process to exit if there are any errors.
set -oue pipefail set -oue pipefail
rm /usr/etc/skel/.config/autostart/bluefin-firstboot.desktop rm /etc/skel/.config/autostart/bluefin-firstboot.desktop

View File

@@ -1,6 +0,0 @@
#!/usr/bin/env bash
# Tell build process to exit if there are any errors.
set -oue pipefail
rm /usr/bin/chsh

View File

@@ -3,4 +3,4 @@
# Tell build process to exit if there are any errors. # Tell build process to exit if there are any errors.
set -oue pipefail set -oue pipefail
chmod 440 /usr/etc/sudoers.d/timeout chmod 440 /etc/sudoers.d/timeout

View File

@@ -3,7 +3,7 @@
# Tell build process to exit if there are any errors. # Tell build process to exit if there are any errors.
set -euo pipefail set -euo pipefail
CONTAINER_DIR="/usr/etc/containers" CONTAINER_DIR="/etc/containers"
MODULE_DIRECTORY="${MODULE_DIRECTORY:-"/tmp/modules"}" MODULE_DIRECTORY="${MODULE_DIRECTORY:-"/tmp/modules"}"
IMAGE_NAME_FILE="${IMAGE_NAME//\//_}" IMAGE_NAME_FILE="${IMAGE_NAME//\//_}"
IMAGE_REGISTRY_TITLE=$(echo "$IMAGE_REGISTRY" | cut -d'/' -f2-) IMAGE_REGISTRY_TITLE=$(echo "$IMAGE_REGISTRY" | cut -d'/' -f2-)
@@ -19,15 +19,15 @@ if ! [ -d $CONTAINER_DIR/registries.d ]; then
mkdir -p "$CONTAINER_DIR/registries.d" mkdir -p "$CONTAINER_DIR/registries.d"
fi fi
if ! [ -d "/usr/etc/pki/containers" ]; then if ! [ -d "/etc/pki/containers" ]; then
mkdir -p "/usr/etc/pki/containers" mkdir -p "/etc/pki/containers"
fi fi
if ! [ -f "$CONTAINER_DIR/policy.json" ]; then if ! [ -f "$CONTAINER_DIR/policy.json" ]; then
cp "$MODULE_DIRECTORY/signing/policy.json" "$CONTAINER_DIR/policy.json" cp "$MODULE_DIRECTORY/signing/policy.json" "$CONTAINER_DIR/policy.json"
fi fi
mv "/usr/etc/pki/containers/$IMAGE_NAME.pub" "/usr/etc/pki/containers/$IMAGE_REGISTRY_TITLE.pub" mv "/etc/pki/containers/$IMAGE_NAME.pub" "/etc/pki/containers/$IMAGE_REGISTRY_TITLE.pub"
POLICY_FILE="$CONTAINER_DIR/policy.json" POLICY_FILE="$CONTAINER_DIR/policy.json"

View File

@@ -1,4 +1,6 @@
type: files type: files
files: files:
- source: system/usr - source: system/usr
destination: /usr destination: /usr
- source: system/etc
destination: /etc