Skip to content

Commit

Permalink
Log the output from uploading files to GCS. (GoogleContainerTools#541)
Browse files Browse the repository at this point in the history
  • Loading branch information
dlorenc authored Jan 23, 2019
1 parent a4b47a4 commit a493035
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion integration/gcs.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,11 @@ func UploadFileToBucket(gcsBucket string, filePath string, gcsPath string) (stri
log.Printf("Uploading file at %s to GCS bucket at %s\n", filePath, dst)

cmd := exec.Command("gsutil", "cp", filePath, dst)
if _, err := RunCommandWithoutTest(cmd); err != nil {
out, err := RunCommandWithoutTest(cmd)
if err != nil {
return "", fmt.Errorf("Failed to copy tarball to GCS bucket %s: %s", gcsBucket, err)
}
log.Println(string(out))

return dst, nil
}
Expand Down

0 comments on commit a493035

Please sign in to comment.