jfrog / terraform-provider-xray

Terraform provider to manage JFrog Xray
https://jfrog.com/xray/
Apache License 2.0
149 stars 12 forks source link

Ability to configure `Allow download and distribute when Xray is unavailable` setting #78

Closed bmanuel closed 6 months ago

bmanuel commented 2 years ago

Is your feature request related to a problem? Please describe. Ensuring that the Allow download and distribute when Xray is unavailable setting is as expected and consistent across installations is tedious since it is not available in the terraform provider.

Describe the solution you'd like A new resource (maybe artifactory_xray_settings) that has a boolean for allow_download_when_unavailable that controls this setting.

Describe alternatives you've considered Scripting API calls. This is less than ideal since the rest of our configuration is handled by terraform.

Additional context

alexhung commented 2 years ago

@bmanuel Thanks for the request, we will add this to our schedule. We will likely add new attribute allow_download_and_distribute_when_unavailable to resource xray_settings.

danielmkn commented 2 years ago

Hi @bmanuel, thank you for raising this ticket! Unfortunately, we can't resolve it right away, because there is no proper API support. This call has no GET request implemented. Also, the call context is artifactory, not xray.

Adding a new resource will be problematic and a workaround would be 'hackish'. Also, there is another way to apply these settings, by using Artifactory configuration API. Allow download and distribute when Xray is unavailable is, in fact, an Artifactory configuration, not Xray. That API has no such option either (for now). So, I've created a feature request to extend the configuration. Once it's implemented, we will add the support to the Terraform Provider.

I suggest you please create a support ticket for JFrog to make things work faster.