Skip to content

Commit 97348a2

Browse files
johnhamelinkmpdude
andauthored
Document on how to integrate with docker/build-push-action (#90)
This change adds some extra clarification to the documentation to show how to setup the `docker/build-push-action` step with this action. This is very helpful when using buildkit's `RUN --mount=type=ssh`. We found this to be a little confusing and the GH issues we found on the matter didn't help! Co-authored-by: Matthias Pigulla <mp@webfactory.de>
1 parent bbd5513 commit 97348a2

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,19 @@ If you know that your favorite tool or platform of choice requires extra tweaks
101101

102102
If you are using this action on container-based workflows, make sure the container has the necessary SSH binaries or package(s) installed.
103103

104+
### Using the `docker/build-push-action` Action
105+
106+
If you are using the `docker/build-push-action`, and would like to pass the SSH key, you can do so by adding the following config to pass the socket file through:
107+
108+
```
109+
- name: Build and push
110+
id: docker_build
111+
uses: docker/build-push-action@v2
112+
with:
113+
ssh: |
114+
default=${{ env.SSH_AUTH_SOCK }}
115+
```
116+
104117
### Cargo's (Rust) Private Dependencies on Windows
105118

106119
If you are using private repositories in your dependencies like this:

0 commit comments

Comments
 (0)