Commit 7a44793
committed
build(task,helm:gen): make dep tgz reproducible
**Problem:** `helm dependency update` packages chart source files with their filesystem modification times. Since git does not preserve file timestamps, every checkout gets different mtimes, producing different tar bytes and thus different `.tgz` files -- even when the file contents are identical.
**Fix (two layers of normalization in `helm:gen`):**
1. **Pre-packaging:** `find ... -exec env TZ=UTC touch -t 200001010000.00 {} +` normalizes all chart source file timestamps to a fixed UTC date before Helm packages them.
2. **Post-packaging:** `dd` patches the gzip header MTIME (bytes 4-7) and OS byte (byte 9) to fixed values, eliminating gzip envelope differences.
Signed-off-by: Patrik Egyed <pregnor@cisco.com>1 parent 122a4f6 commit 7a44793
1 file changed
+21
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2141 | 2141 | | |
2142 | 2142 | | |
2143 | 2143 | | |
2144 | | - | |
2145 | | - | |
2146 | 2144 | | |
2147 | | - | |
| 2145 | + | |
2148 | 2146 | | |
2149 | 2147 | | |
2150 | 2148 | | |
2151 | 2149 | | |
2152 | 2150 | | |
| 2151 | + | |
| 2152 | + | |
| 2153 | + | |
| 2154 | + | |
| 2155 | + | |
| 2156 | + | |
| 2157 | + | |
| 2158 | + | |
| 2159 | + | |
| 2160 | + | |
| 2161 | + | |
| 2162 | + | |
2153 | 2163 | | |
2154 | 2164 | | |
2155 | 2165 | | |
2156 | 2166 | | |
| 2167 | + | |
| 2168 | + | |
| 2169 | + | |
| 2170 | + | |
| 2171 | + | |
| 2172 | + | |
| 2173 | + | |
| 2174 | + | |
2157 | 2175 | | |
2158 | 2176 | | |
2159 | 2177 | | |
| |||
0 commit comments