-
Notifications
You must be signed in to change notification settings - Fork 24
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
Too many "mkosi.extra/" cooks spoil the broth #124
Comments
When cleaning this up, it would be a good time to address the TODO in 936b03c
|
To keep things simple, everything should be copied "as is" IMHO. |
I think it is probably ok to drop the delete. one can always use -r wipe to clean the root. And one often does! ;-)
This is just a time saver I think. For the use case of testing changes in a user space program like ndctl we don't care about the git bits in the guest image. So save the time and don't copy them.
Here you need to do this or the file the link points to may not (probably) won't exist... OK I've done some testing on this feature and it is not working as I would like. I want to include rasdaemon and ras-tool in the guest image. But I don't want the packages. I want the git trees from my home directory. I do not want to clone the tree's directly in the run_qemu repo though. So I did this: 19:26:39 > pwd && ll Which resulted in this in the guest: 19:26:43 > pwd && ll there is no '/home/iweiny' in the guest... 😦 |
Unless someone wants to copy kernel sources, this does not save any measurable time when compared to the total build time.
As usual with symbolic links, "it depends". Symbolic links can also be relative and point to other files copied too. In that case it's best to avoid the duplication: imagine someone wants to make a quick modification while inside the image?
This seems useful but copying stuff outside the run_qemu.git repo is basically a different feature. As a coincidence this was discussed in the "extra-scripts" thread at #122 (comment) I think what would be great is to replace the crude
cc: @stellarhopper |
I don't quite follow why making a quick mod in the image makes a difference here.
extra-scripts was also a hack. This is why I got on this yesterday because I'm wanting to add some ras stuff and I don't want to hard code things like with ndctl. I'm pushing run_qemu to be more generic...
I like this idea. I was also toying with the idea of an additional package list. But I don't know mkosi configs well enough to know the best way to do that. Since I'm wishing for unicorns and ponies here! 😃 Perhaps we should read these config files from the kernel tree? 🤔 That way if you are working on different parts of the kernel the right user space stuff gets installed for the right kernel stuff you are working on. That is where extra-scripts was hacked from. When I worked on PKS I would install the pks test app in there as part of the kernel build. But that got changed with: ef916f3 ("run_qemu: Add kernel selftests build option") Since I'm needing this now let me get a patch together. |
I've changed my mind. I think this is best handled as an option which the user can point wherever they want. They can manage a single file in their source trees and always point run_qemu there or whatever they come up with. |
When you replace an (internal) symlink with a copy, now you need to duplicate any change you want to make. That's IMHO more error-prone and risky than not using
Yes and @stellarhopper said in #122 that he would be happy for
We all want more generic but compiling something will always be project-specific...
I don't remember seeing anything like what we are discussing right now. I mean nothing like "compiling and deploying from source".
Mmmm... not sure why we should un-hardcode locations away from run_qemu.git to re-hardcode them to a location in a different git repo... Ideally, such config files could live anywhere? Maybe with some well chosen default location to save typing? |
So, recent mkosi versions (which ones?) do have a ... but this would complexify the flow and not bring anything to the table. All the
But
Using
We would also have to fit into the mkosi Scripts= framework of the day and lose flexibility to prepare mkosi.extra in any way we want. This would again regularly break across mkosi versions. |
My bad: after a closer look at |
As of today,
git grep mkosi.extra | wc -l
shows 36 hits. It's impossible to tell whether some lines potentially overwrite and generally clash with others.Some
rsync
commands use--delete
which is well intentioned (don't want one run to pollute the next) but is also a risk of conflict.This needs a rethink, redesign and cleanup.
Originally posted by @marc-hb in #122 (comment)
The text was updated successfully, but these errors were encountered: