Commit Graph

38 Commits

Author SHA1 Message Date
harsha.dhake d05c20bb60 Adding credsmgr support in devstack
Change-Id: Ied7da6e314d81426e60063f7347dbeb1dc05216b
2019-06-17 14:36:03 +05:30
Harsha Dhake 3fc8b3f97d Added credentials manager and updated omni drivers.
This change:
1. Adds credmanager service which handles credentials for AWS drivers.
2. Adds support for managing multiple AWS accounts through use of credmanager. Each account is mapped to a single project in keystone.
3. Adds support for multiple AZs by running one nova-compute and cinder-volume process per AZ.
4. Improves support for AWS networking in neutron.
5. Also, made few stability fixes in GCP and Azure drivers.

Change-Id: I0f87005a924423397db659ab754caaa6cde90274
2019-02-25 00:38:42 -05:00
Pratik Shah d407b5f482 [AZURE] Added a fix to create resource group in Azure if not present
Change-Id: I8ad06bd32d381573f794c37a577bb6ff2e056efb
Closes-Bug: #1720982
2017-10-11 09:37:20 +05:30
Sanket Sudake 60cf0c8296 Organizing all Omni specific scripts at one place
Currently we have different scripts to create images or flavors.
Moving all scripts at one place, in future we need to find better way
to manage and package them.

Change-Id: I23ed6218175c9c851547142c8d81eb7a1a32e925
2017-10-04 18:34:46 +05:30
Pratik Shah bcf7055acf [AWS] Added a bug fix for ec2 driver
Description:
- In ec2 driver, driver was trying to connect to regions using
ec2.cloudwatch. It was throwing an AttributeError exception as ec2
don't have cloudwatch module

Change-Id: I9a47d4c63c167a85c57cedbcec59dcb4ebf10f23
2017-10-04 17:40:02 +05:30
Sanket 3e9cad24ba [GCE] Use NoDBTestCase for nova tests
Currently we use nova.test.TestCase which causes db access and
test failure sometimes. Since we don't require database access
in gce nova testcases we can use NoDBTestCase instead.

Change-Id: I47546695ba8a69e494c677d9e542768f34e51250
2017-09-23 00:06:36 +05:30
Sanket d6f6913ee2 [AWS] Remove unused EC2VirtAPI from nova driver
Change-Id: Ief07ab940f8338196848d91785e982bdbd107223
2017-09-21 09:45:12 +00:00
Sanket c547b5523a [GCE] Use instance name instead of instance id for instance mapping
1. Currently we use GCE id for instance mapping from GCE to Openstack.
Since we use GCE name as primary identifier in all GCE operations,
we should use GCE name for mapping.
2. Add Openstack Project ID and User ID in GCE instance metadata
3. Some pep8 fixes in nova code

Change-Id: Id26a674be0f96e2ff5bf89c5ffcca120bd52e0fa
Closes-Bug: #1717889
2017-09-21 09:33:52 +00:00
Sanket 38f171bdea Unit tests fixes in nova and neutron
Patch 1:
[General] Removed unused parameters from InstanceInfo

Many of unused parameters were removed from nova.virt.hardware.InstanceInfo in Pike.
Same was notified to OOT(Out of tree) drivers.

References:
[1] https://review.openstack.org/#/c/471146/6/nova/virt/hardware.py
[2] http://lists.openstack.org/pipermail/openstack-dev/2017-June/117962.html

Closes-Bug: #1717907

Patch 2:
[General] Remove l3_db.subscribe calls from router plugins

l3_db.subscribe has been deprecated from newton. Removing it
was recently disabled from pike release.

Refer bug description for more details.
Closes-Bug: #1718180

Change-Id: Ied1868736c4edb9da839d6d4b49aa1d98cbef251
2017-09-21 14:31:09 +05:30
Jenkins 882ab1d8b1 Merge "Support deletion of keypairs from AWS" 2017-09-13 07:31:56 +00:00
Pushkar Acharya 16d4db46e8 Support deletion of keypairs from AWS
Deletion of keypairs from OpenStack does not trigger a key pair deletion
from AWS. Listen to the keypair deletion notifications and delete the
key from AWS when one is received.

Also pulling in some of the local changes.

Change-Id: Iea466533a8a12c0acccf5b6bf08d99b4e7a1b622
Closes-Bug: #1716454
2017-09-13 00:00:47 -07:00
Sanket 2ee894b7ea [Azure] Attach/detach volume to instance support
Implements: blueprint azure-support

Change-Id: I1d87e94c1ce0aa1e16c2a62f146de9f029cc3fb0
2017-09-11 13:28:00 +05:30
Sanket 92ee8cde01 Cleanup unused requirements from Omni
Consolidating all python requirements required to run unit tests
in test-requirements.txt. Removed rest of all files.

Change-Id: Ifed7288e2b1d92fb180cb8c722578e9887f6f844
2017-09-11 09:39:39 +05:30
Sanket 2def976ad7 Add Azure support for Nova
Change-Id: I05315b83ab28b948caadeadf9be9ecb5fd2c9e5e
Implements: blueprint azure-support
2017-09-08 18:26:32 +00:00
Jenkins 963d736599 Merge "[Trivialfix]Fix typos in omni" 2017-08-31 06:32:40 +00:00
shangxiaobj 1aeb62b0ef [Trivialfix]Fix typos in omni
Fix the typos in omni.

Change-Id: I6e7c1e53752cdf064b12f9de7642af5d138f1463
2017-08-30 02:22:55 -07:00
Pratik Shah ffa3e4c212 [AWS] Added Neutron mechanism test cases
Files modified:
- omni-requirements.txt: Added boto3 package

- run_tests.sh: Added support for running AWS test cases for Neutron

Closes-Bug: #1708586

Change-Id: I91e46a5422a044eeccc171c8f820235e1dc583ef
2017-08-30 11:54:53 +05:30
Sanket 66620a1d4b [GCE] Delete instance on GCE fails with timeout
GCE instance delete operation fails sometimes as it may take
more than 60 sec. Default timeout for wait_for_operation is 60 sec,
which is not sufficient for instance delete operation.

Change-Id: I06f8172a2f87ea5f7972b7624265a3fd0ad576e4
Closes-bug: #1709891
2017-08-11 08:06:10 +05:30
Sanket 249f707233 Enable AWS testcases in Omni tox run with required fixes
Closes-Bug: #1704149

Change-Id: Ib42e1130411bb519cb9d172641a4056c8668bb08
2017-07-31 13:39:34 +05:30
Pratik Shah 264939cfb5 Applied pep8 fixes
Closes-Bug: #1703514

Change-Id: I89c25bd9e678dc2f7cc27f952aa4833e26c90f4a
2017-07-24 16:25:25 +05:30
Pratik Shah 84b9c632f5 Modified tox.ini to clone repos using zuul-cloner
Replaced "," with "%" in logs statement for files:
- cinder/volume/drivers/aws/ebs.py
- cinder/volume/drivers/gce/gceutils.py
- glance/glance_store/_drivers/aws.py
- neutron/neutron/common/gceutils.py
- neutron/neutron/plugins/ml2/drivers/gce/mech_gce.py
- neutron/neutron/plugins/ml2/managers.py
- neutron/neutron/services/l3_router/gce_router_plugin.py
- nova/virt/ec2/ec2driver.py
- nova/virt/gce/driver.py
- nova/virt/gce/gceutils.py

Added import fix in nova/tests/unit/virt/ec2/test_ec2.py

Modified run_tests.sh to get total number of passed and failed tests

Closes-Bug: #1704147

Change-Id: I4b144b8095cf9ff4807c4b9f4ca21577a43de27f
2017-07-14 13:19:22 +05:30
Pratik Shah f2c95ee757 - Add executable permission to clone_repos.sh and run_tests.sh
- Removed AWS tests temporarily from run_tests.sh as they are failing
with credential error.

- Removed check from run_tests.sh which was used to run tests on
devstack setup.

- Fixed LOG statement bug for Cinder driver

- Fixed Nova braces bug for Nova tests

Closes-Bug: #1704124

Change-Id: Id94e44e848555bf6a96b9ef0b0c276579169987c
2017-07-13 19:28:21 +05:30
kavithahr d85752fdda Fixed order of arguments in assertEqual
Some tests used incorrect order of arguments in
assertEqual(observed, expected). The correct order expected
by testtool is assertEqual(expected, observed).

Change-Id: I707f67d3239b7a250ef3bcbf8923fb0575a1d7f1
2017-07-10 17:41:06 +05:30
Jenkins 14f8258865 Merge "Remove translation of log messages" 2017-06-30 18:32:52 +00:00
Sanket f9af3a8d2b Fix disk name in Nova snapshot procedure
Description:
After instance name change, Create volume from disk snapshot fails in instance snapshot
procedure as length of disk name goes beyond 61 chars.
GCE resource name should be in format '(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?)'

Before change:
>>> len('vol-novasnap-inst-7b51c5e2-17a5-435a-a068-61326e6058c21496985304')
64

After change:
>>> len('vol-nsnap-inst-7b51c5e2-17a5-435a-a068-61326e6058c21496985304')
61

Change-Id: I4a21dd7e73c4d219ca7d6cbc5b2647634ffa43d8
2017-06-29 10:10:21 +00:00
Ngo Quoc Cuong 7823d3ddb4 Remove translation of log messages
The i18n team has decided not to translate the logs because it
seems like it not very useful; operators prefer to have them in
English so that they can search for those strings on the internet.

cinder, nova, neutron and glance are removing i18n log translation
functions, once it release, it will cause omni build failed.

Related-Bug: #1701139

Change-Id: I090fde16602945035cbda66f0633371d3dfebd3c
2017-06-28 21:25:52 -04:00
Pratik Shah 699caafaa0 Added tox integration to run unit tests for Omni project.
Description:

1. Fixed file paths in Nova, Neutron according to actual Openstack repository.
2. tox.ini: init file to run to tox command
3. run_tests.sh: actual script to run unit tests
4. omni-requirements.txt: Contains Python packages from Nova, Glance, Neutron and Cinder

Usage:
To run unit tests, execute 'tox -epy27' command in Omni project directory.

Change-Id: Ife3a5d4c009198fb46faff7a21525dd739a87e9c
2017-06-19 16:17:03 +05:30
Sanket 02798d0ed5 Fix Nova spawn testcase for instance name change
Change-Id: I921095e82a0b60b45675ec450efeb9698d3bcf9f
2017-06-05 09:39:44 +05:30
Jenkins d827041474 Merge "Unit Testcases for GCE Nova Driver" 2017-06-02 15:02:32 +00:00
Sanket 40e6f7b0ee Added Nova Instace Snapshot Operation and security group rules support
1. Added instance snapshot feature
2. Support for security group rules using GCE firewall rules
2. Added disk, snapshot related operations nova gceutils library
3. Cleanup unwanted operations from glance gceutils library

Change-Id: I1777e99cf4e1f7c230c4a9b286e4c01e8deb3d2f
Signed-off-by: Sanket <sanket@infracloud.io>
2017-06-01 14:42:58 +05:30
Pratik Shah bae0816470 Unit Testcases for GCE Nova Driver
Additional data files in gce/data:

1. Fake service key file(omni.json)
2. Data required to generate Gce Service(service_data.json)
3. Fake disk data for attach_volume and detach_volume API(get_disk.json)
4. Fake instance data(get_instance.json)
5. Fake list of instances(list_instances.json)
6. Machines information for flavor information(list_machines_info.json)
7. Fake instance data with boot value False(get_instance_without_boot.json)
8. Fake image data(get_image.json)

Change-Id: Ib8bf42c93e4a2f8f1c821a26b2868dfda993eadd
2017-05-30 17:48:30 +05:30
Sanket Sudake 1de5c3778c Add Cinder support for GCE
Supported operations:
1. Create/delete a volume
2. Snapshot a volume
3. Create a volume from snapshot
4. Attach/detach volume to an instance

Change-Id: I5b2a9ee964fc239153d6de9886cc5e4a8e743c17
Signed-off-by: Sanket <sanket@infracloud.io>
2017-05-08 10:50:13 +05:30
Sanket e4fd7a04f5 Add Neutron Support for GCE
1. ML2 Mechanism Driver for GCE
2. Router Service plugin for GCE

Change-Id: Id8d009f1b57cb37701be1957588ef5edd0acaf1c
Implements: blueprint gce-support
Signed-off-by: Sanket <sanket@infracloud.io>
2017-05-02 13:15:16 +05:30
Sanket 9a11c06e3b Add Glance Store Driver for GCE
1. Consists of Glance store Driver and mechanism to discover GCE images
and them to Glance catalog as Glance images
2. Pick up correct Glance flavor in instance spawn
3. Mechanism to populate nova flavors from GCE machine info

Implements: blueprint gce-support
Change-Id: Iab71206b760ed6f516484690030d9ecb6c891e68
Signed-off-by: Sanket <sanket@infracloud.io>
2017-04-19 10:20:11 +05:30
Sanket Sudake 6b4e6aac86 Add Nova driver for GCE
Consists of Nova driver for GCE which performs basic operations
like spawning instance, start, stop etc through openstack.

Implements: blueprint gce-support
Change-Id: Id04b093cc3828446ebf5e40f4e4829ea32748bc0
Signed-off-by: Sanket <sanket@infracloud.io>
2017-04-12 00:01:32 +05:30
Pushkar Acharya 2e684990f3 Update nova driver to Platform9 2.4 release
This commit updates the nova driver to latest release of Platform9.
Some of the notable changes include:
1. Addition of unit tests
2. Configurable maximum usable resources i.e. memory, disk and cpu
3. Better integration for security groups with latest changes in neutron
2017-01-04 14:41:44 -08:00
yanheven 57dbef940e Add requirements.txt to nova, glance and cinder driver directiory,
and add boto as prerequesites to README.MD of cinder.
2016-10-26 13:21:39 +02:00
Sachin fa89beafab Initial commit: Introducing AWS Drivers for OpenStack 2016-10-26 00:12:14 -07:00