Skip to content
Open
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
Empty file.
3 changes: 0 additions & 3 deletions kernel/mkosi.build
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,6 @@ else
mkosi-chroot --chdir "/build/kernel-${KERNEL_VERSION}" make olddefconfig
mkosi-chroot --chdir "/build/kernel-${KERNEL_VERSION}" make -j "$(nproc 2>/dev/null || echo 2)" bzImage ARCH=x86_64 CONFIG_EFI_STUB=y

echo "# kernel config:"
mkosi-chroot --chdir "/build/kernel-${KERNEL_VERSION}" cat .config

# Cache result
mkdir -p "$cache_dir"
cp arch/x86_64/boot/bzImage "$cache_dir/"
Expand Down
8 changes: 4 additions & 4 deletions l2/_op_rbuilder/mkosi.build
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ source scripts/build_rust_package.sh

# build op-rbuilder

if [ -f "l2/_op_rbuilder/mkosi.extra/usr/bin/op-rbuilder" ]; then
if [ -f "$SRCDIR/l2/_op_rbuilder/mkosi.extra/usr/bin/op-rbuilder" ]; then
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion:

let's ditch all these if-elses whatsoever (they are no longer needed).

echo "Using pre-built op-rbuilder binary"
else
build_rust_package \
Expand All @@ -34,7 +34,7 @@ fi

# build tdx-quote-provider

if [ -f "l2/_op_rbuilder/mkosi.extra/usr/bin/tdx-quote-provider" ]; then
if [ -f "$SRCDIR/l2/_op_rbuilder/mkosi.extra/usr/bin/tdx-quote-provider" ]; then
echo "Using pre-built tdx-quote-provider binary"
else
build_rust_package \
Expand All @@ -46,7 +46,7 @@ fi

# build rproxy

if [ -f "l2/_op_rbuilder/mkosi.extra/usr/bin/rproxy" ]; then
if [ -f "$SRCDIR/l2/_op_rbuilder/mkosi.extra/usr/bin/rproxy" ]; then
echo "Using pre-built rproxy binary"
else
make_git_package \
Expand All @@ -60,7 +60,7 @@ fi

# build node-healthchecker

if [ -f "l2/mkosi.extra/usr/bin/node-healthchecker" ]; then
if [ -f "$SRCDIR/l2/mkosi.extra/usr/bin/node-healthchecker" ]; then
echo "Using pre-built node-healthchecker binary"
else
make_git_package \
Expand Down
8 changes: 8 additions & 0 deletions l2/mkosi.postinst
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,11 @@ mkosi-chroot chmod 0770 /vault/secrets
mkosi-chroot chmod 0750 /etc/vault-agent
mkosi-chroot chmod 0750 /etc/vault-agent/gomplate
mkosi-chroot sh -c "chmod 0640 /etc/vault-agent/gomplate/*"

# Create /etc/sysconfig for vault-agent
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion:

this is not only for vault-agent, but for any systemd service that will need some secrets injected via env var.

Suggested change
# Create /etc/sysconfig for vault-agent
# Create /etc/sysconfig secrets injection


mkosi-chroot mkdir -p /etc/sysconfig

# Limit root filesystem size to 4GB

mkosi-chroot sed -i '1a mount -o remount,size=4G /' /init
45 changes: 0 additions & 45 deletions mkosi.profiles/gcp/mkosi.extra/etc/systemd/journald.conf
Original file line number Diff line number Diff line change
@@ -1,50 +1,5 @@
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it under the
# terms of the GNU Lesser General Public License as published by the Free
# Software Foundation; either version 2.1 of the License, or (at your option)
# any later version.
#
# Entries in this file show the compile time defaults. Local configuration
# should be created by either modifying this file (or a copy of it placed in
# /etc/ if the original file is shipped in /usr/), or by creating "drop-ins" in
# the /etc/systemd/journald.conf.d/ directory. The latter is generally
# recommended. Defaults can be restored by simply deleting the main
# configuration file and all drop-ins located in /etc/.
#
# Use 'systemd-analyze cat-config systemd/journald.conf' to display the full config.
#
# See journald.conf(5) for details.

[Journal]
#Storage=auto
#Compress=yes
#Seal=yes
#SplitMode=uid
#SyncIntervalSec=5m
#RateLimitIntervalSec=30s
#RateLimitBurst=10000
#SystemMaxUse=
#SystemKeepFree=
SystemMaxFileSize=128M
SystemMaxFiles=2
#RuntimeMaxUse=64K
#RuntimeKeepFree=
RuntimeMaxFileSize=512K
RuntimeMaxFiles=2
#MaxRetentionSec=0
#MaxFileSec=1month
#ForwardToSyslog=no
#ForwardToKMsg=no
#ForwardToConsole=no
#ForwardToWall=yes
#TTYPath=/dev/console
#MaxLevelStore=debug
#MaxLevelSyslog=debug
#MaxLevelKMsg=notice
#MaxLevelConsole=info
#MaxLevelWall=emerg
#MaxLevelSocket=debug
#LineMax=48K
#ReadKMsg=yes
#Audit=yes
4 changes: 0 additions & 4 deletions mkosi.profiles/gcp/mkosi.postinst
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ if [ -f /etc/rsyslog.d/50-default.conf ]; then
sed -i 's/^.*\/var\/log\/syslog.*$/# &/' /etc/rsyslog.d/50-default.conf
fi

# Limit root filesystem size to 4GB

mkosi-chroot sed -i '1a mount -o remount,size=4G /' /init

# Remove automatically generated nvme data

rm -rf "$BUILDROOT/etc/nvme/hostid" "$BUILDROOT/etc/nvme/hostnqn"