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

host/base: investigate dropping lua interpreter from rootfs/PATH #275

Closed
lucab opened this issue Sep 5, 2018 · 7 comments
Closed

host/base: investigate dropping lua interpreter from rootfs/PATH #275

lucab opened this issue Sep 5, 2018 · 7 comments

Comments

@lucab
Copy link
Contributor

lucab commented Sep 5, 2018

It looks like we are currently shipping an unversioned lua interpreter in PATH:

$ which lua
/bin/lua

$ lua -v
Lua 5.1.4  Copyright (C) 1994-2008 Lua.org, PUC-Rio

From a quick look around the rootfs and rpm-db, I didn't spot any other lua modules. It is probably not as bad as the python ecosystem, but we shouldn't have external consumers depending on this.

@lucab
Copy link
Contributor Author

lucab commented Sep 5, 2018

Quick followup, it looks like the lua package is brought-in because of the following base packages:

authconfig-6.2.8-30.el7.x86_64
grub2-1:2.02-0.44.el7.x86_64
grub2-efi-1:2.02-0.44.el7.x86_64
grub2-tools-1:2.02-0.44.el7.x86_64
libsolv-0.6.26-2.el7.x86_64
ostree-grub2-2018.8.1-0d6ead1bffe8a38067444d527669f0a7b84997fd.5bb0359caf4facc535ee3ee8b5ec7c552637c28d.el7.centos.x86_64
policycoreutils-2.5-22.el7.x86_64
policycoreutils-python-2.5-22.el7.x86_64
rpm-4.11.3-32.el7.x86_64
rpm-libs-4.11.3-32.el7.x86_64
rpm-ostree-2018.7.12-6a274b831d2dea7fa8c05a82999f205ab16393b9.9c43f986d3e4ec41d98132ff40399eebe541ffd6.el7.centos.x86_64
rpm-ostree-libs-2018.7.12-6a274b831d2dea7fa8c05a82999f205ab16393b9.9c43f986d3e4ec41d98132ff40399eebe541ffd6.el7.centos.x86_64

The lua rpm provides both the interpreter and the liblua .so at the same time, so hopefully most of those dependencies could be just for the library part (i.e. not a real need for an in-path interpreter).

@cgwalters
Copy link
Member

https://bugzilla.redhat.com/show_bug.cgi?id=1360404

@lucab
Copy link
Contributor Author

lucab commented Sep 5, 2018

@cgwalters nice! Does that mean that it is already sorted out on ootpa or is there anything still to be tracked there?

@cgwalters
Copy link
Member

Yes, already fixed in ootpa. For maipo we could probably just rm -f /usr/bin/lua in the postprocess?

@lucab
Copy link
Contributor Author

lucab commented Sep 6, 2018

I did an additional quick check in bin / sbin / lib / libexec in the maipo image and I didn't see anything referencing the interpreter directly, so I think it is fine to filter it and good doing that now.

@cgwalters as a curiosity, is there a difference in suggesting a rm in postprocess vs. remove-from-packages?

cgwalters added a commit to cgwalters/os that referenced this issue Sep 6, 2018
@cgwalters
Copy link
Member

@cgwalters as a curiosity, is there a difference in suggesting a rm in postprocess vs. remove-from-packages?

I honestly forget the latter exists sometimes...it's fairly convenient to just rm in shell script. But the nice use case of remove-from-packages is exactly this one, we want to nuke everything in /usr/bin just from the lua package. So that's what the PR did, thanks for the reminder 😄

@cgwalters
Copy link
Member

Random aside, the remove-from-packages concept was taken from lorax, which is what builds the anaconda ISOs.

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

No branches or pull requests

2 participants