Add tee
All checks were successful
Create and publish a Docker image / build-and-push-image (push) Successful in 55s

This commit is contained in:
Alexandre Bruyant 2024-01-07 15:50:23 +01:00
parent 4fb1933f07
commit 81a0a9f9e8

View File

@ -91,8 +91,10 @@ func main() {
body, writer := io.Pipe()
r := io.TeeReader(body, os.Stdout)
url := fmt.Sprintf("http://%v:%v/api/v0/add", ipfsHost, ipfsPort)
req, err := http.NewRequest(http.MethodPost, url, body)
req, err := http.NewRequest(http.MethodPost, url, r)
if err != nil {
githubactions.Fatalf("Unable to create request: %v", err.Error())
}