Skip to content

Feature hourly and quote based bare metal server#161

Merged
renier merged 35 commits intomasterfrom
feature-custom-baremetal
Jul 17, 2017
Merged

Feature hourly and quote based bare metal server#161
renier merged 35 commits intomasterfrom
feature-custom-baremetal

Conversation

@minsikl
Copy link
Contributor

@minsikl minsikl commented Jul 14, 2017

I cloned the PR #151 and extended the bare metal resource.

The following functions are added.
Added hourly bare metal server provisioning functions.

  • CPU, Memory, Disk and RAID configuration functions

Added quote based bare metal server provisioning functions.

Added quote_bare_metal data source.

  • Data source which retrieves hourly bare metal server order information.

steven4ibm and others added 30 commits May 26, 2017 10:06
Optional: true,
ForceNew: true,
DiffSuppressFunc: applyOnce,
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought we were going to rely on information from the quote data source to fill in properties in the compute resource. Can you explain why we need the quote_id here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can create a bare metal server with the quote_id attribute.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, so they can't use the data source for this? If not, what is the value-add of the quote data source?

Copy link
Contributor Author

@minsikl minsikl Jul 15, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quote data source provides required attributes for bare metal provisioning. You can refer to the quote data source to define a bare metal server resource. Or you can use interpolations to define a bare metal server resource. For example,

package_key_name = "${data.softlayer_quote_bare_metal.bm1.package_key_name}"
...

If you want to define a bare metal server resource with a quote data, you can write a definition as follows:

data softlayer_quote_bare_metal quote_bm1{
  name = "quote1"
}

resource softlayer_bare_metal bm1 {
...
quote_id = "${data.softlayer_quote_bare_metal.quote_bm1.id}"
...
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see why we would need both a quote id and a quote data source. Let's talk about that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Per your request, the quote_bare_metal data source was deleted.

@renier renier merged commit b34cd32 into master Jul 17, 2017
@renier renier deleted the feature-custom-baremetal branch July 17, 2017 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants