Comment 3 for bug 1902010

Revision history for this message
Thiago F. Pappacena (pappacena) wrote :

I can understand why receiving external information at docker image's build time could be useful, but I agree that free-form shell code might be too broad.

Maybe using ARG to format a pre-defined set of information could a middle ground here. I'm thinking something like this, defined at ARG UI field:
MY_VAR1=xxx
BUILD_TIME={lp_now:%Y-%m-%d %H:%m:%S}
REVISION={lp_repository_revision}

Then, at buildd, we can format the ARG values using our set of pre-defined programmatic values and formatters (https://www.python.org/dev/peps/pep-3101/).

But of course, we would need to have a list of which variables could be useful, if we go in this direction.