Skip to content

Commit

Permalink
Add boolean field for content_default_http_proxy in HTTProxy entity (#…
Browse files Browse the repository at this point in the history
…1254)

* Add boolean field for content_default_http_proxy in HTTProxy entity

Signed-off-by: Gaurav Talreja <[email protected]>

* Ignore content_default_http_proxy param for SAT-30769

Signed-off-by: Gaurav Talreja <[email protected]>

---------

Signed-off-by: Gaurav Talreja <[email protected]>
  • Loading branch information
Gauravtalreja1 authored Feb 14, 2025
1 parent 9719949 commit 7ef23c0
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions nailgun/entities.py
Original file line number Diff line number Diff line change
Expand Up @@ -5534,6 +5534,7 @@ def __init__(self, server_config=None, **kwargs):
'organization': entity_fields.OneToManyField(Organization),
'location': entity_fields.OneToManyField(Location),
'cacert': entity_fields.StringField(),
'content_default_http_proxy': entity_fields.BooleanField(),
}
self._meta = {'api_path': 'api/v2/http_proxies'}
super().__init__(server_config=server_config, **kwargs)
Expand All @@ -5556,12 +5557,17 @@ def read(self, entity=None, attrs=None, ignore=None, params=None):
For more information, see `Bugzilla #1779642
<https://bugzilla.redhat.com/show_bug.cgi?id=1779642>`_.
"""
if attrs is None:
attrs = self.read_json()
if ignore is None:
ignore = set()
ignore.add('password')
ignore.add('organization')
ignore.add('location')
ignore.add('cacert')
# Workaround for SAT-30769
if 'content_default_http_proxy' not in attrs:
ignore.add('content_default_http_proxy')
return super().read(entity, attrs, ignore, params)


Expand Down

0 comments on commit 7ef23c0

Please sign in to comment.