2018-03-29 23:50:58 -04:00
|
|
|
// +build go1.10
|
|
|
|
|
|
|
|
package compress
|
|
|
|
|
2018-06-26 14:06:37 -04:00
|
|
|
import (
|
|
|
|
"archive/tar"
|
|
|
|
"time"
|
|
|
|
)
|
2018-03-29 23:50:58 -04:00
|
|
|
|
|
|
|
func setHeaderFormat(header *tar.Header) {
|
|
|
|
// We have to set the Format explicitly for the googlecompute-import
|
|
|
|
// post-processor. Google Cloud only allows importing GNU tar format.
|
|
|
|
header.Format = tar.FormatGNU
|
2018-06-26 14:06:37 -04:00
|
|
|
header.AccessTime = time.Time{}
|
|
|
|
header.ModTime = time.Time{}
|
|
|
|
header.ChangeTime = time.Time{}
|
2018-03-29 23:50:58 -04:00
|
|
|
}
|