Skip to content

fix: alpine bash issue #1786

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

Closed

Conversation

LizenzFass78851
Copy link
Contributor

Description

This creates a symlink for the test and [ commands to make them executable via busybox and not coreutils. It writes commands to disable the bash internal test and [ commands both in the bashrc (for interactive sessions) and in a separate sh file that is used as a script for non-interactive sessions (specified via an env). This way, at least the execution of bash internal commands like test and [ can be prevented and these busybox commands can be used instead.

Motivation and Context

This (hopefully) fixes: #1767

How Has This Been Tested?

I tested this on an Ubuntu 20.04 VM with an outdated containerd.io package to be able to reproduce the bash alpine issue and test its fix. More details here.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@yubiuser
Copy link
Member

Thanks for this. I'm currently unable to test this (vacation 🎉) but this is something I had in mind.

If this works as intended, I would also revert pi-hole/pi-hole#6030 as this is more a workout then the proper fix and has it's own regressions.

mwoolweaver added a commit to mwoolweaver/pi-hole that referenced this pull request Mar 14, 2025
in preparation for pi-hole/docker-pi-hole/pull/1786

Signed-off-by: Michael Woolweaver <[email protected]>
@LizenzFass78851 LizenzFass78851 force-pushed the fix/alpine-issue branch 2 times, most recently from b1818ad to 8ce4f5a Compare March 15, 2025 10:04
@LizenzFass78851 LizenzFass78851 changed the title Fix: alpine bash issue fix: alpine bash issue Mar 15, 2025
Signed-off-by: LizenzFass78851 <[email protected]>
- chmod of fix alpine issue is not needed
- change directory and name of non-interactive sh file
- change name of env

Signed-off-by: LizenzFass78851 <[email protected]>
@LizenzFass78851 LizenzFass78851 marked this pull request as draft March 24, 2025 19:26
@LizenzFass78851 LizenzFass78851 deleted the fix/alpine-issue branch March 25, 2025 05:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants