terraform-provider-cloudflare icon indicating copy to clipboard operation
terraform-provider-cloudflare copied to clipboard

add datasource to pull all available log fields

Open vital4ik opened this issue 3 years ago • 4 comments

Current Terraform version

0.14.8

Description

is it possible to add a datasource to pull all the log fields? they are available here: https://api.cloudflare.com/client/v4/zones/<zone_id>/logpush/datasets//fields.

Use cases

in order to properly construct the logpush job that is up to date with the fields available, would be nice to have it as a datasource

Potential Terraform configuration

none

References

No response

vital4ik avatar Mar 25 '21 20:03 vital4ik

hi @jacobbednarz, which upstream library needs to be updated for this? using null provisioner with local exec to get this is very fragile

vitdolphin avatar May 19 '21 23:05 vitdolphin

the terraform provider uses cloudflare-go under the hood for the API calls; it doesn't implement anything itself. so before we can do anything here, that library needs it.

jacobbednarz avatar May 19 '21 23:05 jacobbednarz

cloudflare-go should support the required api calls now that it supports account-level logpush jobs via GetAccountLogpushFields and GetZoneLogpushFields. I'll probably try to get around to working on a PR this week unless someone else works on it.

tjstansell avatar Jan 05 '22 06:01 tjstansell

fwiw, i've also requested that logpush/logpull simply support fields=ALL or similar to remove this requirement entirely when you just want everything... but who knows if/when that'll ever get implemented.

tjstansell avatar Jan 05 '22 18:01 tjstansell

This issue has been closed as we are now tracking this internally with service teams directly. If you would like an update or to be notified when/if the product ships with this change, please reach out to Cloudflare Support or your account team who can watch the internal feature request for you.

jacobbednarz avatar Mar 25 '24 00:03 jacobbednarz