Skip to content

Commit

Permalink
Infer the registry FQDN from the server FQDN
Browse files Browse the repository at this point in the history
The registry FQDN should have the same domain and framework as
the server FQDN, as such, no option to set a different value in the CLI args
  • Loading branch information
jesusbv committed May 24, 2024
1 parent f43a759 commit cae6fa6
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions usr/sbin/registercloudguest
Original file line number Diff line number Diff line change
Expand Up @@ -214,12 +214,6 @@ argparse.add_argument(
dest='user_smt_fqdn',
help=help_msg
)
help_msg='The target registry server FQDN. '
argparse.add_argument(
'--smt-registry-fqdn',
dest='user_registry_fqdn',
help=help_msg
)
help_msg='The target update server IP. '
help_msg+='Use in exceptional cases only'
argparse.add_argument(
Expand Down Expand Up @@ -362,7 +356,8 @@ if args.user_smt_ip:
elif isinstance(smt_ip, ipaddress.IPv4Address):
smt_xml += 'SMTserverIP="%s" ' % args.user_smt_ip
smt_xml += 'SMTserverName="%s" ' % args.user_smt_fqdn
smt_xml += 'SMTregistryName="%s"' % args.user_registry_fqdn
registry_fqdn = 'registry-{}'.format(args.user_smt_fqdn.split('-')[2])
smt_xml += 'SMTregistryName="%s"' % registry_fqdn
smt_xml += '/></regionSMTdata>'
region_smt_data = etree.fromstring(smt_xml)
else:
Expand Down

0 comments on commit cae6fa6

Please sign in to comment.