natIP: can not reference an IP resource

165 views
Skip to first unread message

Hermann Angstl

unread,
Oct 30, 2018, 12:28:05 PM10/30/18
to gce-discussion
I created a static external IP with Deployment Manager code. No Problem.

I'd like to use this IP to create an Compute Engine Instance.

Setting the field "networkIP" to the URL of an IP ressource works fine, but setting the field "natIP" to such a resource does not work. "natIP" only works with IP addresses (e.g. 35.241.113.34) and not with links to an IP a resource.

Am I doing something wrong or is this a design inconsistency in the API?
          
Example code:

        'name': 'status-tool',
        'type': 'compute.v1.instance',
        'properties': {
        ...
                'networkInterfaces': [{
                        'networkIP': 'https://www.googleapis.com/compute/v1/projects/ccp-management/regions/europe-west1/addresses/...',        # works
                        'accessConfigs': [{
                                'name': 'External NAT',
                                'type': 'ONE_TO_ONE_NAT',
                                'natIP': 'https://www.googleapis.com/compute/v1/projects/ccp-management/regions/europe-west1/addresses/...',    # does not work
                        }]
                }]        
        ...

Setting "natIP" to such a value results in a ResourceErrorMessage (Invalid value for field 'resource.networkInterfaces[0].accessConfigs[0].natIP).

Ishtiaque

unread,
Oct 31, 2018, 1:01:24 PM10/31/18
to gce-discussion
Hello Hermann,

I see that you have submitted a bug report through Google Public Issue Tracker (PIT) for the same concern. Therefore, I would suggest that you follow the PIT thread regarding further update on this issue.

Thank you.  
Reply all
Reply to author
Forward
0 new messages