Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[Update] Run-parts #466

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

[Update] Run-parts #466

wants to merge 1 commit into from

Conversation

Aegrah
Copy link

@Aegrah Aegrah commented Aug 27, 2024

Summary

This PR adds command execution capabilities to the run-parts binary. Run-parts is capable of executing shell scripts, which allows for proxied command execution.

> root@vm:/home/ruben_groenewoud# printf '#!/bin/sh\n/bin/sh -c "/bin/id > /tmp/id.out"\n' > /tmp/run-parts/id && chmod +x /tmp/run-parts/id

> root@vm:/home/ruben_groenewoud# cat /tmp/run-parts/id 

#!/bin/sh
/bin/sh -c "/bin/id > /tmp/id.out"

> root@vm:/home/ruben_groenewoud# run-parts /tmp/run-parts

> root@vm:/home/ruben_groenewoud# cat /tmp/id.out 

uid=0(root) gid=0(root) groups=0(root)

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant