debian-forge-composer/internal
Ondřej Budai 454e471af8 api/weldr: bring tars back from the future
By default, go's tar archiver uses USTAR header format. Unfortunately, this
format doesn't support sub-second resolution for ModTime. Go solves this by
*rounding* the time. Sometimes, this creates an archive containing a file
with modtime from the future. When such archive is untarred by GNU tar,
the following message is produced:

tar: bf548dfd-0a90-40e6-bbf2-dcdd82fcbb4e.json: time stamp 2020-07-13
13:34:31 is 0.356223173 s in the future

We have two options here:

1) Use gnu header format that supports sub-second resolution. Unfortunately,
   it seems that not all tar archivers support this format (e.g. 7-zip).

2) The other option is to truncate the date (instead of rounding).

I went with option 2.

Also, this commit adds a test to check that the header is not from the future.
Without this fix, the test is actually failing, I verified this manually.

Fixes #854
2020-07-15 08:58:25 +01:00
..
blueprint blueprint: do not append "-" to name-version if version is empty 2020-06-10 17:40:30 +02:00
client test: add a test-case to prevent bad multilib depsolves 2020-06-10 17:40:30 +02:00
common common/ImageType: move to the store package 2020-05-18 11:50:15 +02:00
crypt crypt_test: don't run on macOS 2020-04-09 13:21:30 +02:00
distro 📦 Use raw image format for AWS 2020-07-02 13:11:11 -05:00
jobqueue jobqueue: allow canceling jobs 2020-05-13 16:45:09 +02:00
jsondb jsondb: Allow passing nil as document to Read() 2020-05-13 16:45:09 +02:00
mocks worker: introduce job artifact directory 2020-05-26 10:42:20 +02:00
osbuild osbuild: pass UID/GID as int 2020-06-29 16:04:38 +02:00
rcm distro: replace BasePackages() with Packages() 2020-06-29 16:04:38 +02:00
rpmmd rpmmd/Depsolve: expose whether to check GPG signature for each RPM 2020-06-10 19:25:54 +02:00
store distro/rhel8: add RHEL for Edge 2020-06-11 20:44:17 +02:00
target store: move queue out of the store 2020-05-08 14:53:00 +02:00
test weldr: add support for toml format in /blueprints/freeze 2020-06-05 13:51:04 +02:00
upload Add more emojis to AWS upload logs 2020-06-05 19:56:57 +02:00
weldr api/weldr: bring tars back from the future 2020-07-15 08:58:25 +01:00
worker worker: Check OSBuildOutput for nil before using it 2020-06-12 12:45:46 +02:00