logoalt Hacker News

adastra22last Thursday at 8:12 PM1 replyview on HN

So put the binary in the container. Why does it have to be compiled within the container?


Replies

hu3last Thursday at 8:24 PM

That is what they are doing. It's a 2 stage Dockerfile.

First stage compiles the code. This is good for isolation and reproducibility.

Second stage is a lightweight container to run the compiled binary.

Why is the author being attacked (by multiple comments) for not making things simpler when that was not claimed that as the goal. They are modernizing it.

Containers are good practice for CI/CD anyway.

show 3 replies