siderolabs / conform

Policy enforcement for your pipelines.
Mozilla Public License 2.0
432 stars 45 forks source link

fix: create a temp dir on hook requests, not a file #252

Closed utkuozdemir closed 8 months ago

utkuozdemir commented 8 months ago

This was migrated from the deprecated ioutil.TempDir in a wrong way, so it was attempting to create a temp file instead of a directory. Was never deployed, so went unnoticed.

utkuozdemir commented 8 months ago

Btw, a good question would be: why do we write event payloads into disk? I guess it's for debugging, but it is not that easy to get into /tmp when it's running in a pod without sh or anything. Maybe a better idea would be to bring zap into the project and just log it with debug level.

utkuozdemir commented 8 months ago

/m