-
Notifications
You must be signed in to change notification settings - Fork 103
prost: Move external tool into build-script #831
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
Conversation
84d2b13
to
3647b43
Compare
I have to say the 4000k+ new files in the vendor folder hurt! I think the previous PR #829 that moved prost-build into the Dockerfile was a better solution because of this. And as that PR states, it should speed up builds, right? 🤔 What happens if you disable the default features in the prost-build dep? Would that reduce the number of vendored files? |
Good idea to try reducing features, yeah the other option would be to install the tool in the container instead. If we keep it as it is it complicates cargo test, so I suggest we do one of the solutions. |
The thing is, In the end this also makes the project more self-reliant. If we build it in a dockerfile and crates.io has downtime / or some government takes it down, then we cannot rebuild the docker image / project anymore... |
Yeah that is true, but still ;)
I think this is a lesser issue - Dockerfiles are built very rarely, so temporary downtimes are not so bad. We also generally expect Docker builds to become non-reproducible over time or even fail to build, as inevitably some upstream stuff changes or disappears.
One of, being this PR or moving it to the Dockerfile? |
Yeah exactly |
i am scared and i think there's a substantial risk: |
Let's go with #829 instead. The Docker image is already uploaded with tag 22. |
The files are either in vendor, or built into prost-build (which does not vendor, so fetched upstream every time). Is that a significant difference in terms of supply chain risk? I would not think it is a big difference, either can do harm. Just because they are not vendored it does not mean they don't exist. The solution here is to maybe patch the prost dep to have less transitive deps or disable them somehow (if not already possible via feature gates). |
right. the deps do exist either way but look at the insane deps graph:
half of this comes from clap, just for 2 cmd line args - could be easily replaced with a tempfile pulls in the whole libc, rand_chacha and other stuff. that's just crazy. are there alternatives to prost-build? |
I made a PR to remove clap in favour of lexopt that doesn't have any deps and has the same level of correctness. But that wasn't deemed necessary when we go to prebuild the tool in docker |
I think prost build the lib has a reasonable amount of deps and for the right purposes. Many items in that tree are duplicates |
No description provided.