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

Provide outputs as env vars #257

Merged
merged 2 commits into from Jan 13, 2023
Merged

Provide outputs as env vars #257

merged 2 commits into from Jan 13, 2023

Conversation

crazy-max
Copy link
Member

@crazy-max crazy-max commented Jan 13, 2023

@crazy-max crazy-max requested a review from jedevc January 13, 2023 10:14
@crazy-max crazy-max marked this pull request as ready for review January 13, 2023 10:14
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Comment on lines +308 to +315
So it can be used with our [Docker Build Push action](https://github.com/docker/build-push-action/):

```yaml
- uses: docker/build-push-action@v3
with:
build-args: |
DOCKER_METADATA_OUTPUT_JSON
```
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't find docs in build-push-action that describe the syntax for this - we should probably add that on merging this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes it's a core implementation where you can use --build-arg flag without a value: https://docs.docker.com/engine/reference/commandline/build/#-set-build-time-variables---build-arg

You may also use the --build-arg flag without a value, in which case the value
from the local environment will be propagated into the Docker container being
built:

$ export HTTP_PROXY=http://10.20.30.2:1234
$ docker build --build-arg HTTP_PROXY .

@crazy-max crazy-max merged commit 507c2f2 into docker:master Jan 13, 2023
@crazy-max crazy-max deleted the env-output branch January 13, 2023 13:33
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

Successfully merging this pull request may close these issues.

None yet

2 participants