Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

salt-cloud will use list_floating_ips for Openstack #34280

Merged
merged 1 commit into from
Jun 24, 2016

Conversation

kevinanderson1
Copy link
Contributor

What does this PR do?

When using salt-cloud on an Openstack installation, attempting to provision a machine with public_ips while a project has maxed out the quota for floating-ips but has unassigned IP's in the pool results in a HTTP 413 error. It appears the code calls get create_floating_ips instead of using unassigned IP's in the pool. This changes the behavior to use IP's from the pool and errors if none are assigned.

What issues does this PR fix or reference?

N/A

Previous Behavior

salt-cloud would call create_floating_ips to get a floating IP to assign to an instance when provisioning

New Behavior

salt-cloud will call list_floating_ips and use any unassigned IP currently in the pool for provisioing

Tests written?

No

Please review Salt's Contributing Guide for best practices.

This changes salt-cloud for Openstack to list_floating_ips when
nodes are provisioned. This prevents quota errors whe attempting
to allocate IPs to a project when the quota is maxed out but there
are unassigned IPs.

This changes salt-cloud for Openstack to list_floating_ips when
nodes are provisioned. This prevents quota errors whe attempting
to allocate IPs to a project when the quota is maxed out but there
are unassigned IPs.
@rallytime
Copy link
Contributor

Thanks @kevinanderson1!

@rallytime rallytime merged commit d8716a7 into saltstack:develop Jun 24, 2016
gitebra pushed a commit to gitebra/salt that referenced this pull request Jun 27, 2016
* upstream/develop: (24 commits)
  salt-cloud will use list_floating_ips for Openstack (saltstack#34280)
  Update Azure ARM driver to support 2.0rc5 (saltstack#34251)
  Pylint fix
  Refactoring a bit to keep the CLI fast (saltstack#33997)
  file.find module: fix handling of broken symlinks
  Fixed typo in filtering LDAP's potential_ous
  Port boto_rds to Boto3 version 1.3.1
  Minor lint fix.
  External auth can return dynamically generated ACL from auth call.
  Fixes saltstack#34135, Fixes saltstack#34137
  some cleanup and renaming
  better way to check for openSUSE Leap
  Fix for openSUSE Tumbleweed
  fixes for fopen mock and some os_release_map for SLES11SP3
  unit tests for SUSE os grains detection
  Normalization of osfullname grain for openSUSE
  one clause to set OS grain from CPE_NAME
  Test fixed: get OS grain from /etc/os-release if possible
  fix: osarch_mock
  osarch mock for unit test
  ...

# Conflicts:
#	salt/modules/boto_rds.py
cachedout pushed a commit that referenced this pull request Jan 26, 2017
this will use list_floating_ips as well for recent versions of
libcloud. To not break with current setups create_floating_ip is used in
case no free ip in the pool exists. The latter is as well a minor fixup
to #34280 (i.e. older versions of libcloud)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants