Closed george-angel closed 6 years ago
Currently files are being base64 encoded and labelled with the following header: data:text/plain;charset=utf-8;base64,<value>
data:text/plain;charset=utf-8;base64,<value>
base64 encoding plaintext results in a larger byte count (important for AWS userdata)
for example our fairly standard kubernetes apiserver manifest has the following byte count:
plain - 2378 b64 - 3180 gzip+b64 - 1208
2378
3180
1208
considering AWS allows up to 16KB pre base64'd data, gziping files would make a huge difference. A single file resource can save 2k!
the only "gotcha" I haven't looked into is whether ignition can parse base64gzip'd files.
Happy to work on a PR if the idea is sound.
I read up a bit more about it, and ultimately this is constrained by the data uri spec. Closing for now.
Currently files are being base64 encoded and labelled with the following header:
data:text/plain;charset=utf-8;base64,<value>
base64 encoding plaintext results in a larger byte count (important for AWS userdata)
for example our fairly standard kubernetes apiserver manifest has the following byte count:
plain -
2378
b64 -3180
gzip+b64 -1208
considering AWS allows up to 16KB pre base64'd data, gziping files would make a huge difference. A single file resource can save 2k!
the only "gotcha" I haven't looked into is whether ignition can parse base64gzip'd files.
Happy to work on a PR if the idea is sound.