Merge "Remove undercloud deploy"

This commit is contained in:
Zuul 2019-07-03 16:45:31 +00:00 committed by Gerrit Code Review
commit 6d06c2aa1a
4 changed files with 5 additions and 84 deletions

View File

@ -0,0 +1,5 @@
---
upgrade:
- |
The `openstack undercloud deploy` command has been removed. Use `openstack
tripleo deploy` instead.

View File

@ -106,7 +106,6 @@ openstack.tripleoclient.v1 =
tripleo_container_image_list = tripleoclient.v1.container_image:TripleOContainerImageList
tripleo_container_image_prepare = tripleoclient.v1.container_image:TripleOImagePrepare
tripleo_container_image_prepare_default = tripleoclient.v1.container_image:TripleOImagePrepareDefault
undercloud_deploy = tripleoclient.v1.undercloud_deploy:DeployUndercloud
undercloud_install = tripleoclient.v1.undercloud:InstallUndercloud
undercloud_upgrade = tripleoclient.v1.undercloud:UpgradeUndercloud
undercloud_minion_install = tripleoclient.v1.undercloud_minion:InstallUndercloudMinion

View File

@ -1,48 +0,0 @@
# Copyright 2015 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
#
import mock
from osc_lib.tests import utils
# Load the plugin init module for the plugin list and show commands
from tripleoclient.v1 import undercloud_deploy
class TestDeployUndercloud(utils.TestCommand):
def setUp(self):
super(TestDeployUndercloud, self).setUp()
# Get the command object to test
self.cmd = undercloud_deploy.DeployUndercloud(self.app, None)
@mock.patch('tripleoclient.v1.tripleo_deploy.Deploy.take_action',
autospec=True)
def test_take_action(self, mock_deploy):
parsed_args = self.check_parser(self.cmd,
['--local-ip', '127.0.0.1',
'--templates', '/tmp/thtroot',
'--stack', 'undercloud',
'--output-dir', '/my',
'-e', '/tmp/thtroot/puppet/foo.yaml',
'-e', '/tmp/thtroot//docker/bar.yaml',
'-e', '/tmp/thtroot42/notouch.yaml',
'-e', '~/custom.yaml',
'-e', 'something.yaml',
'-e', '../../../outside.yaml'], [])
self.cmd.take_action(parsed_args)
parsed_args.standlone = True
mock_deploy.assert_called_with(self.cmd, parsed_args)

View File

@ -1,35 +0,0 @@
# Copyright 2016 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
#
from __future__ import print_function
import logging
from tripleoclient.v1.tripleo_deploy import Deploy
class DeployUndercloud(Deploy):
"""Deploy containerized Undercloud"""
log = logging.getLogger(__name__ + ".DeployUndercloud")
def take_action(self, parsed_args):
self.log.debug("take_action(%s)" % parsed_args)
self.log.warning("The undercloud deploy action is deprecated. Please "
"use the tripleo deploy --standalone action.")
# add in --standalone if we were invoked via undercloud deploy
parsed_args.standalone = True
parsed_args.standalone_role = 'Undercloud'
super(DeployUndercloud, self).take_action(parsed_args)