Skip to content

Commit

Permalink
stick to assisted library 2.27 until it's pushed to prod
Browse files Browse the repository at this point in the history
  • Loading branch information
karmab committed Nov 30, 2023
1 parent 99b7b3c commit 33923c1
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 27 deletions.
54 changes: 28 additions & 26 deletions ailib/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,32 +201,34 @@ def set_default_values(self, overrides, existing=False, quiet=False):
overrides['openshift_version'] = str(overrides['openshift_version'])
if overrides['openshift_version'] == 4.1:
overrides['openshift_version'] = '4.10'
service_networks = overrides.get('service_networks', [])
dual = len(service_networks) > 1 and ':' in service_networks[1]
api_ip = overrides.get('api_vip') or overrides.get('api_ip')
if api_ip is not None:
if not dual:
if 'api_ip' in overrides:
del overrides['api_ip']
if 'api_vip' in overrides:
del overrides['api_vip']
warning("Ignoring api_ip at creation time", quiet=quiet or existing)
ingress_ip = overrides.get('ingress_vip') or overrides.get('ingress_ip')
if ingress_ip is not None:
if not dual:
if 'ingress_ip' in overrides:
del overrides['ingress_ip']
if 'ingress_vip' in overrides:
del overrides['ingress_vip']
warning("Ignoring ingress_ip at creation time", quiet=quiet or existing)
api_vips = overrides.get('api_vips', [])
if not dual and api_vips:
warning("Ignoring api_vips at creation time", quiet=quiet or existing)
del overrides['api_vips']
ingress_vips = overrides.get('ingress_vips', [])
if not dual and ingress_vips:
warning("Ignoring ingress_vips at creation time", quiet=quiet or existing)
del overrides['ingress_vips']
# service_networks = overrides.get('service_networks', [])
# dual = len(service_networks) > 1 and ':' in service_networks[1]
api_vip = overrides.get('api_vip') or overrides.get('api_ip')
if api_vip is not None:
overrides['api_vip'] = api_vip
# if not dual:
# if 'api_ip' in overrides:
# del overrides['api_ip']
# if 'api_vip' in overrides:
# del overrides['api_vip']
# warning("Ignoring api_ip at creation time", quiet=quiet or existing)
ingress_vip = overrides.get('ingress_vip') or overrides.get('ingress_ip')
if ingress_vip is not None:
overrides['ingress_vip'] = ingress_vip
# if not dual:
# if 'ingress_ip' in overrides:
# del overrides['ingress_ip']
# if 'ingress_vip' in overrides:
# del overrides['ingress_vip']
# warning("Ignoring ingress_ip at creation time", quiet=quiet or existing)
# api_vips = overrides.get('api_vips', [])
# if not dual and api_vips:
# warning("Ignoring api_vips at creation time", quiet=quiet or existing)
# del overrides['api_vips']
# ingress_vips = overrides.get('ingress_vips', [])
# if not dual and ingress_vips:
# warning("Ignoring ingress_vips at creation time", quiet=quiet or existing)
# del overrides['ingress_vips']
if not existing:
if 'pull_secret' not in overrides:
warning("Using openshift_pull.json as pull_secret file", quiet=quiet)
Expand Down
1 change: 1 addition & 0 deletions assisted-service-client.spec
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ assisted-installer python library
{{{ git_dir_setup_macro }}}

%build
git checkout v2.27.0
curl https://repo1.maven.org/maven2/io/swagger/swagger-codegen-cli/2.4.8/swagger-codegen-cli-2.4.8.jar > swagger-codegen-cli.jar
curl https://raw.githubusercontent.com/openshift/assisted-service/master/swagger.yaml > swagger.yaml
sed -i '/pattern:/d' swagger.yaml
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from setuptools import setup, find_packages

import os
INSTALL = ['assisted-service-client', 'prettytable', 'PyYAML']
INSTALL = ['assisted-service-client<2.28.0.post1', 'prettytable', 'PyYAML']
description = 'Assisted installer assistant'
long_description = description
if os.path.exists('README.rst'):
Expand Down

0 comments on commit 33923c1

Please sign in to comment.