Skip to content

Commit

Permalink
Add support for debian repository creation
Browse files Browse the repository at this point in the history
  • Loading branch information
dosas committed Jul 2, 2024
1 parent f18649a commit 3f99bfe
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion nailgun/entities.py
Original file line number Diff line number Diff line change
Expand Up @@ -6833,7 +6833,7 @@ def __init__(self, server_config=None, **kwargs):
),
'content_counts': entity_fields.DictField(),
'content_type': entity_fields.StringField(
choices=('puppet', 'yum', 'file', 'docker', 'ostree'),
choices=('puppet', 'yum', 'file', 'docker', 'ostree', 'deb'),
default='yum',
required=True,
),
Expand Down Expand Up @@ -6874,12 +6874,19 @@ def __init__(self, server_config=None, **kwargs):
choices=('global_default_http_proxy', 'none', 'use_selected_http_proxy')
),
'http_proxy_id': entity_fields.IntegerField(),
'deb_releases': entity_fields.StringField(),
'deb_errata_url': entity_fields.StringField(),
'deb_components': entity_fields.StringField(),
'deb_architectures': entity_fields.StringField(),
}
if self._fields['content_type'].choices == 'yum':
self._fields['download_policy'].required = True
self._meta = {
'api_path': 'katello/api/v2/repositories',
}
if self._fields['content_type'].choices == 'deb':
self._fields['deb_releases'].required = True
self._fields['deb_releases'].default = 'stable'
super().__init__(server_config=server_config, **kwargs)

def path(self, which=None):
Expand Down

0 comments on commit 3f99bfe

Please sign in to comment.