Commit Graph

219 Commits

Author SHA1 Message Date
Joe Topjian 669ddbfc5c Merge pull request #4288 from jtopjian/jtopjian-openstack-bfv-set2list
provider/openstack: Convert block_device from TypeSet to TypeList
2015-12-16 23:05:00 -07:00
Joe Topjian 03a7926198 Merge pull request #4298 from jtopjian/jtopjian-openstack-devstack
provider/openstack: DevStack Deploy Script
2015-12-16 11:44:12 -07:00
Joe Topjian 1ff403347b provider/openstack: Fix set hash for security group test 2015-12-13 03:15:52 +00:00
Joe Topjian 7cbd18a88d provider/openstack: DevStack Deploy Script
This commit includes a script to deploy a standardized devstack environment
for use with development and testing.
2015-12-13 02:58:29 +00:00
Joe Topjian 4716451617 provider/openstack: Convert block_device from TypeSet to TypeList
This change better reflects how block devices are passed to the Nova API
and allows for future enablement of block_device features. It also resolves
an interpolation bug.
2015-12-12 22:18:23 +00:00
Joe Topjian 3dc45039d1 Merge pull request #4204 from jtopjian/jtopjian-openstack-deleting-volume
provider/openstack: Handle volumes in "deleting" state
2015-12-08 22:58:32 -07:00
Nic Grayson ef9838c796 increased openstack 10 minute timeouts to 30 minutes 2015-12-08 16:03:33 -06:00
Joe Topjian c3f6bbcece provider/openstack: Handle volumes in "deleting" state
This commit prevents Terraform from erroring when an attempt is made
to delete a volume already in a "deleting" state. This can happen when
the volume is the root disk of an instance and the instance was
terminated.
2015-12-08 06:33:06 +00:00
Joe Topjian f9dd42ddce provider/openstack: Add State Change support to LBaaS Resources
This commit adds State Change support to the LBaaS resources which should
help with clean terminations.

It also adds an acceptance tests that builds out a 2-node load balance
service.
2015-11-19 04:33:53 +00:00
Joe Topjian b4242e6f35 provider/openstack: Clean up some attributes in LBaaS VIP resource
This commit makes a few attributes computed so the generated information
is accessible after creation.

It also fixes the "persistence" attribute, which previously had a typo.

Finally, it converts "admin_state_up" to a Boolean to match the majority
of other attributes of the same name.
2015-11-14 21:16:23 +00:00
Radek Simko e7c88eab35 openstack: fix go vet error (bool modifier is %t) 2015-11-14 08:19:22 +00:00
Joe Topjian 19fc2193f4 Merge pull request #3904 from jtopjian/jtopjian-openstack-port-attr-cleanup
provider/openstack: Make Networking Port attributes more intuitive
2015-11-13 20:15:29 -07:00
Joe Topjian f2a5064538 Merge pull request #3857 from jtopjian/jtopjian-openstack-secgroup-rule-fix2
provider/openstack: Security Group Rule fixes
2015-11-13 20:13:46 -07:00
Joe Topjian edd8e722bf provider/openstack: Make Networking Port attributes more intuitive
This commit makes some quick updates to the port attributes to make them
more intuitive:

* `security_groups` to `security_group_ids`: since the port is expecting
IDs and not security group names like in other areas of OpenStack.

* `admin_state_up`: change to Boolean to match this same attribute on
other resources.

* `fixed_ips` to `fixed_ip`: while multiple `fixed_ip` blocks can be
specified, only one fixed IP can be specified in each block.
2015-11-13 04:46:12 +00:00
Joe Topjian 4d6e3289bc provider/openstack: adding test for router interface port 2015-11-13 04:04:05 +00:00
Kirill Shirinkin 3a1a242a7a provider/openstack: Allow port_id for router interface 2015-11-13 03:13:12 +00:00
Joe Topjian 3db7922b53 provider/openstack: Security Group Rule fixes
This commit fixes an issue with security group rules where the rules
were not being correctly computed due to a typo in the rule map.

Once rules were successfully computed, the rules then needed to be
converted into a Set so they can be correctly ordered.
2015-11-12 03:15:52 +00:00
Joe Topjian 29636dc51d provider/openstack: Revert Security Group Rule Fix
This commit reverts the patch from #3796.

It has been discovered that multiple rules are being reported out
of order when the configuration is applied multiple times. I feel
this is a larger issue than the bug this patch originally fixed,
so until I can resolve it, I am reverting the patch.
2015-11-09 17:31:40 +00:00
Joe Topjian 37d4316c13 Merge pull request #3801 from jtopjian/jtopjian-openstack-secgroup-computed
provider/openstack: Make Security Groups Computed
2015-11-07 12:31:15 -07:00
Joe Topjian 98a441314b provider/openstack: Make Security Groups Computed
This commit makes security groups in the openstack_compute_instance_v2
resource computed. This fixes issues where a security group is omitted
which causes the instance to have the "default" group applied. When
re-applying without this patch, an error will occur.
2015-11-07 04:01:50 +00:00
Joe Topjian 0e9397fc74 provider/openstack: Security Group Rules Fix
This commit fixes how security group rules are read by Terraform and
enables them to be correctly removed when the rule resource is
modified.
2015-11-06 21:52:30 +00:00
Joe Topjian 4c1083c9c5 provider/openstack: fix test formatting 2015-11-06 17:32:30 +00:00
Kirill Shirinkin d5e6929118 Fix tests 2015-11-06 11:10:44 +01:00
Kirill Shirinkin 3a63b48f97 provider/openstack: fixed_ips implementation for ports 2015-11-05 19:23:05 +01:00
Joe Topjian 312d371ce9 provider/openstack: Additions to the OpenStack Port resource
This commit adds further work to the OpenStack port resource:

* Makes relevant fields computed
* Adds state change functions
* Adds acceptance tests
* Adds Documentation
2015-11-03 06:07:32 +00:00
Jean Mertz 7d11b4b7e7 provider/openstack: openstack_networking_port_v2 resource 2015-11-03 05:35:05 +00:00
Joe Topjian cc54d9e0fd provider/openstack: State Changes for Networking Resources
This commit adds create and delete state change checks for the "core"
networking resources.
2015-11-03 05:12:22 +00:00
Joe Topjian 4a5cd0b415 provider/openstack: Fixing Image ID/Name areas
This commit cleans up areas that configure the image_id and image_name.

It enables the ability to not have to specify an image_id or image_name
when booting from a volume.

It also prevents Terraform from reporting an error when an image name is no
longer able to be resolved from an image ID. This usually happens when the
image has been deleted, but there are still running instances that were based
off of it.

The image_id and image_name parameters no longer immediately take a default
value from the OS_IMAGE_ID and OS_IMAGE_NAME environment variables. If no other
resolution of an image_id or image_name were found, then these variables will
be referenced. This further supports booting from a volume.

Finally, documentation was updated to take into account booting from a volume.
2015-10-31 22:45:34 +00:00
Joe Topjian 3d3f8122a9 provider/openstack: Volume Cleanup
This commit cleans up the volume and block device handling in the instance
resource. It also adds more acceptance tests to deal with different workflows
of attaching and detaching a volume through the instance's lifecycle.

No new functionality has been added.
2015-10-31 22:45:34 +00:00
Joe Topjian e75553fd9d provider/openstack: Fixes Boot From Volume
This commit fixes the previously broken "boot from volume" feature. It also
adds an acceptance test to ensure the feature continues to work.

The "delete_on_termination" option was also added.
2015-10-31 22:45:28 +00:00
Joe Topjian cc2b3677e6 Merge pull request #3091 from berendt/openstack_subnet_ip_default
provider/openstack: use '4' as default for ip_version of subnet
2015-10-31 22:15:48 +09:00
Joe Topjian 776f15f0f3 provider/openstack: added acceptance test to test security group order 2015-10-30 22:31:41 +00:00
Joe Topjian beab5619e2 Merge pull request #3651 from Sheile/ignore-sg-order
provider/openstack: Ignore order of security_groups in instance
2015-10-30 22:35:06 +09:00
Joe Topjian c4c480bb92 provider/openstack: Safe SecGroup Delete
This commit enables security groups to be deleted in a safe way by
checking their state over a period of time.

This fixes occurrences when the API says the instance is deleted but
it is still in the process of being deleted by OpenStack and thus the
security group returns an error saying that there are still instances
attached to the group.
2015-10-30 13:03:26 +00:00
Joe Topjian fd8dba4827 provider/openstack: add state 'creating' to blockstorage_volume_v1
This commit adds the "creating" status to the Pending phases of creating a
block storage device.

Closes #3224
2015-10-29 19:01:24 -05:00
Paul Hinze fe2bf2d473 Merge pull request #3440 from ggiamarchi/openstack/idempotency
Fix OpenStack provider idempotency bugs
2015-10-29 18:57:02 -05:00
Yo Takezawa 59828deb0f provider/openstack: Use security_groups as native set when update 2015-10-28 10:12:05 +09:00
Yo Takezawa d2cf45a057 provider/openstack: Ignore order of security_groups in instance 2015-10-27 15:57:28 +09:00
Panagiotis Moustafellos e4845f75cc removed extra parentheses 2015-10-08 15:48:04 +03:00
Guillaume Giamarchi e453decec8 Fix OpenStack provider idempotency bugs 2015-10-07 22:39:12 +02:00
Radek Simko f9efede852 gofmt files from recently merged PRs 2015-10-07 13:35:06 -07:00
Paul Hinze 5b4bbf08d0 Merge pull request #1788 from JeanMertz/openstack-floatingip-port
OpenStack: add functionality to attach FloatingIP to Port
2015-10-05 14:30:26 -05:00
Paul Hinze 50b8161da1 Merge pull request #2008 from dupuy/secgrp-delta-remove-then-add
remove security groups (by name) before adding security groups (by id)
2015-09-24 14:14:48 -05:00
Anthony Scalisi 198e1a5186 remove various typos 2015-09-11 11:56:20 -07:00
Christian Berendt 3af3ce4242 provider/openstack: use '4' as default for ip_version of subnet 2015-08-27 18:27:14 +02:00
Christian Berendt b38f0e2f67 provider/openstack: add state 'downloading' to resource 'blockstorage_volume_v1'
When using an image as the source of new volume the state 'downloading'
prior to the state 'available' is fine.

It is also fine to destroy a volume in the state 'downloading'.

Closes-bug: #2865
Co-Authored-By: Joe Topjian <joe@topjian.net>
2015-08-24 08:21:35 +02:00
Joe Topjian 5251193f87 Allow empty api_key and endpoint_type
These two provider options are optional though if they are not set,
the user will be prompted to enter values.

By changing them to use the envDefaultFuncAllowMissing, the values
are still passed in the environment if they are set and safely
discarded if they are not.
2015-07-06 03:14:13 +00:00
Mitchell Hashimoto ebc33d874a providers/openstack: fix vet issue 2015-06-24 23:16:06 -07:00
Mitchell Hashimoto ede6af8763 Merge pull request #1921 from jtopjian/openstack-servergroup-schedulerhints
provider/openstack: scheduler_hints and servergroups
2015-06-24 23:13:25 -07:00
Mitchell Hashimoto d1d2a90158 Revert "provider/openstack: change security groups to set"
This reverts commit 646fd76e07.
2015-06-24 23:10:30 -07:00