Skip to content
Merged
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
27 changes: 27 additions & 0 deletions .github/actions/test/integration/build/dev-user-butane.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,30 @@ storage:
contents:
inline: |
OCI_REPO=ghcr.io/gardenlinux/gardenlinux-ccloud
# Enable unlimited core dumps for all systemd services
- path: /etc/systemd/system.conf.d/10-core.conf
mode: 0644
contents:
inline: |
[Manager]
DefaultLimitCORE=infinity
# Configure systemd-coredump with reasonable limits
- path: /etc/systemd/coredump.conf.d/50-ci-core.conf
mode: 0644
contents:
inline: |
[Coredump]
Storage=external
ProcessSizeMax=3G
ExternalSizeMax=3G
MaxUse=2G
KeepFree=1G
Compress=yes
# Set kernel core pattern to use systemd-coredump
- path: /etc/sysctl.d/50-core.conf
mode: 0644
contents:
inline: |
kernel.core_pattern=|/usr/lib/systemd/systemd-coredump %P %u %g %s %t %c %h
kernel.core_pipe_limit=16
fs.suid_dumpable=2
37 changes: 36 additions & 1 deletion .github/actions/test/integration/collect-logs/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,44 @@ runs:
run: |
sudo chmod 644 *.log

- name: Upload artifacts
- name: Collect coredumps from hypervisors
shell: bash
run: |
KEY=/opt/ssh_host_ed25519_key
SSH_OPTS="-i $KEY -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
USER="root"

for HV_NAME in HV1 HV2; do
IP="192.168.122.$([[ $HV_NAME == HV1 ]] && echo 2 || echo 3)"

ssh $SSH_OPTS $USER@$IP "
# Only proceed if coredumps exist
if coredumpctl list --no-legend 2>/dev/null | grep -q .; then
mkdir -p /tmp/coredumps-$HV_NAME
for id in \$(coredumpctl list --no-legend 2>/dev/null | awk '{print \$5}'); do
echo Processing core \$id
coredumpctl info \$id > /tmp/coredumps-$HV_NAME/info-\$id.txt 2>/dev/null || true
coredumpctl dump \$id > /tmp/coredumps-$HV_NAME/core-\$id 2>/dev/null || true
done
else
echo 'No coredumps present on $HV_NAME'
fi
" || true

if ssh $SSH_OPTS $USER@$IP "[ -d /tmp/coredumps-$HV_NAME ] && [ -n \"\$(ls /tmp/coredumps-$HV_NAME 2>/dev/null)\" ]"; then
scp -r $SSH_OPTS $USER@$IP:/tmp/coredumps-$HV_NAME ./ || true
fi
done

- name: Upload debug logs
uses: actions/upload-artifact@v4
with:
name: debug-logs
path: "*.log"

- name: Upload coredumps (if any exist)
uses: actions/upload-artifact@v4
if: ${{ hashFiles('coredumps-*/**') != '' }}
with:
name: coredumps
path: coredumps-*/