shwstppr opened a new pull request #3489: server: fix public IP 
association/disassociation to new network
URL: https://github.com/apache/cloudstack/pull/3489
 
 
   ## Description
   Fixes #3321 
   
   This changes removes exception throwing while associating an IP address to a 
new isolated network which is in `Allocated` state. And it allows 
disassociating an IP address when it is used for source NAT purpose but network 
is in allocated state.
   Refer, 
https://github.com/apache/cloudstack/issues/3321#issuecomment-510389806
   
   ## Types of changes
   <!--- What types of changes does your code introduce? Put an `x` in all the 
boxes that apply: -->
   - [ ] Breaking change (fix or feature that would cause existing 
functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [x] Bug fix (non-breaking change which fixes an issue)
   - [ ] Enhancement (improves an existing feature and functionality)
   - [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
   
   ## Screenshots (if appropriate):
   
   ## How Has This Been Tested?
   Using cmk,
   ```
   (localcloud) 🐱 > list networks filter=id,name,state
   {
     "count": 1,
     "network": [
       {
         "id": "6838a64f-2f55-4097-af9f-c0cdff805737",
         "name": "Test",
         "state": "Allocated"
       }
     ]
   }
   (localcloud) 🐱 > associate ipaddress 
networkid=6838a64f-2f55-4097-af9f-c0cdff805737 
   {
     "ipaddress": {
       "account": "admin",
       "allocated": "2019-07-12T15:29:07+0530",
       "associatednetworkid": "6838a64f-2f55-4097-af9f-c0cdff805737",
       "associatednetworkname": "Test",
       "domain": "ROOT",
       "domainid": "5b4d6fd0-a486-11e9-a980-645d8651f45a",
       "fordisplay": true,
       "forvirtualnetwork": true,
       "id": "8e8593dd-b38c-4272-8748-bdd87de5997f",
       "ipaddress": "192.168.2.4",
       "isportable": false,
       "issourcenat": true,
       "isstaticnat": false,
       "issystem": false,
       "networkid": "09e7940c-a642-41c1-9bad-47d9d97fb1d5",
       "physicalnetworkid": "e964a192-5883-4e07-afdb-a30ef5ea69fe",
       "state": "Allocating",
       "tags": [],
       "vlanid": "3421057d-5a58-45cd-b451-e26de05f7417",
       "vlanname": "vlan://50",
       "zoneid": "c9db52ce-6425-4460-aed4-cb00b67b02e8",
       "zonename": "Sandbox-simulator"
     }
   }
   (localcloud) 🐱 > disassociate ipaddress 
id=8e8593dd-b38c-4272-8748-bdd87de5997f
   {
     "success": true
   }
   
   ```
   
   
   <!-- Please read the 
[CONTRIBUTING](https://github.com/apache/cloudstack/blob/master/CONTRIBUTING.md)
 document -->
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to