import argparse import imp import os import re import socket import sys import textwrap from oslo.config import cfg import six import stevedore.named from nova.openstack.common import gettextutils from nova.openstack.common import importutils gettextutils.install('nova') STROPT = "StrOpt" BOOLOPT = "BoolOpt" INTOPT = "IntOpt" FLOATOPT = "FloatOpt" LISTOPT = "ListOpt" DICTOPT = "DictOpt" MULTISTROPT = "MultiStrOpt" OPT_TYPES = { STROPT: 'string value', BOOLOPT: 'boolean value', INTOPT: 'integer value', FLOATOPT: 'floating point value', LISTOPT: 'list value',
#!/usr/bin/python import socket import sys import nova.openstack.common.gettextutils as gtutil gtutil.install('') import nova.virt.libvirt.vif as vif_driver from nova.network import linux_net from nova.network import model as network_model from neutronclient.neutron import client as qclient import neutronclient.common.exceptions as qcexp # LOG = logging.getLogger(__name__) # Arg 1: controller host # Arg 2: name of admin user # Arg 3: admin user password # Arg 4: tenant name # Arg 5: uuid of VM # Arg 6: MAC address of tap interface # Arg 7: hostname # Arg 8: name of tap interface host = sys.argv[1] user = sys.argv[2] pw = sys.argv[3] tenant = sys.argv[4] vm_uuid = sys.argv[5] mac_addr = sys.argv[6] hostname = sys.argv[7]
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. import os import sys import time os.environ['EVENTLET_NO_GREENDNS'] = 'yes' import eventlet eventlet.monkey_patch(os=False) from oslo.config import cfg from nova.openstack.common import gettextutils gettextutils.install('novadbtest') from nova import context from nova import config from nova import db from nova.openstack.common import jsonutils from nova.openstack.common import log as logging CONF = cfg.CONF CONF.import_opt('connection', 'nova.openstack.common.db.sqlalchemy.session', group='database') LOG = logging.getLogger(__name__) cli_opts = [ cfg.IntOpt('total',
from __future__ import print_function import imp import os import re import socket import sys import textwrap from oslo.config import cfg import six from nova.openstack.common import gettextutils from nova.openstack.common import importutils gettextutils.install('nova') STROPT = "StrOpt" BOOLOPT = "BoolOpt" INTOPT = "IntOpt" FLOATOPT = "FloatOpt" LISTOPT = "ListOpt" MULTISTROPT = "MultiStrOpt" OPT_TYPES = { STROPT: 'string value', BOOLOPT: 'boolean value', INTOPT: 'integer value', FLOATOPT: 'floating point value', LISTOPT: 'list value', MULTISTROPT: 'multi valued',
#!/usr/bin/python import socket import sys import nova.openstack.common.gettextutils as gtutil gtutil.install('') import nova.virt.libvirt.vif as vif_driver from nova.network import linux_net from nova.network import model as network_model from neutronclient.neutron import client as qclient import neutronclient.common.exceptions as qcexp # LOG = logging.getLogger(__name__) # Arg 1: controller host # Arg 2: name of admin user # Arg 3: admin user password # Arg 4: tenant name # Arg 5: uuid of VM # Arg 6: MAC address of tap interface # Arg 7: hostname # Arg 8: name of tap interface host = sys.argv[1] user = sys.argv[2] pw = sys.argv[3] tenant = sys.argv[4] vm_uuid = sys.argv[5] mac_addr = sys.argv[6] hostname = sys.argv[7]
# 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 argparse # FIXME(bknudson): need to move commands somewhere else. from nova.openstack.common import gettextutils gettextutils.install("nova") from nova.compute.ibm import configuration_strategy from nova.compute.ibm import configuration_strategy_common as common from nova.compute.ibm.sysprep import unattend from nova.openstack.common import log as logging from nova.openstack.common.gettextutils import _ LOG = logging.getLogger(__name__) class ConfigurationStrategy(configuration_strategy.ConfigurationStrategy): """Implements configuration strategy for windows sysprep."""