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

test: debug dns resolve on armbian based images #299

Closed
wants to merge 12 commits into from
Closed
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
12 changes: 6 additions & 6 deletions .github/workflow_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@

buildtest:
# armbian based images
- armbian/bananapim2zero
- armbian/orangepi3lts
# - armbian/bananapim2zero
# - armbian/orangepi3lts
- armbian/orangepi4lts
- armbian/orangepi_zero2
# - armbian/orangepi_zero2
# Orange Pi OS based images
# Raspberry Pi OS based images
- raspberry/rpi32
- raspberry/rpi64
# - raspberry/rpi32
# - raspberry/rpi64
# rpi 64 with KS
- raspberry/rpi64-ks
# - raspberry/rpi64-ks

# This is used to setup release build chain.
# Each entry will be used in setup matrix for releases
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/BuildImages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ jobs:
uses: ./repository/.github/actions/build
with:
config: ${{ matrix.config }}
custompios-repository: KwadFan/CustomPiOS
custompios-ref: fix/chrootmount

- name: Rename image file
id: move-image
Expand Down
3 changes: 2 additions & 1 deletion config/armbian/default
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ BASE_IMAGE_RESIZEROOT=600
# Compress not needed due compression done in workflow
BASE_RELEASE_COMPRESS=no
# Modules are valid for 32bit and 64bit images
MODULES="base(pkgupgrade,udev_fix,armbian(armbian_net,mainsailos,klipper,is_req_preinstall,moonraker,mainsail,timelapse,crowsnest,sonar))"
# MODULES="base(pkgupgrade,udev_fix,armbian(armbian_net,mainsailos,klipper,is_req_preinstall,moonraker,mainsail,timelapse,crowsnest,sonar))"
MODULES="base(debug)"

# export Variables
export DOWNLOAD_BASE_URL
Expand Down
1 change: 1 addition & 0 deletions src/modules/debug/config
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Intentionally left blank
68 changes: 68 additions & 0 deletions src/modules/debug/start_chroot_script
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
#!/usr/bin/env bash

## Source error handling, leave this in place
set -Eex

## Set LC_ALL to prevent errors
export LC_ALL=C

# Set DEBIAN_FRONTEND to noninteractive
if [[ "${DEBIAN_FRONTEND}" != "noninteractive" ]]; then
export DEBIAN_FRONTEND=noninteractive
fi

## Source CustomPIOS common.sh
# shellcheck disable=SC1091
source /common.sh
install_cleanup_trap


echo_red "DEBUG: -------------------------------------------------"
cd /
ls -al /run/systemd/resolve/stub-resolv.conf || true
cat /run/systemd/resolve/stub-resolv.conf || true

echo_red "--------------------------------------------------------"



echo_red "--------------------------------------------------------"

resolvectl status

echo_red "--------------------------------------------------------"


ping -c 2 google.de || true

echo_red "DEBUG: --------------------------------------------------"

echo_green "Try to alter dns ---------------------------------------"

echo "nameserver 1.1.1.1" > /etc/resolv.conf
sudo systemctl restart systemd-resolved

echo_green "Try to alter dns ---------------------------------------"

echo_red "DEBUG: -------------------------------------------------"
cd /
ls -al /run/systemd/resolve/stub-resolv.conf || true
cat /run/systemd/resolve/stub-resolv.conf || true

echo_red "--------------------------------------------------------"



echo_red "--------------------------------------------------------"

resolvectl status

echo_red "--------------------------------------------------------"


ping -c 2 google.de || true

echo_red "DEBUG: --------------------------------------------------"

# Let it fail anyways!
exit 1
Loading