GCP: Allow to set MinCpuPlatform

This commit is contained in:
Adrien Delorme 2018-08-21 10:09:30 +02:00
parent e37f126cf1
commit b038cd10f5
3 changed files with 4 additions and 1 deletions

View File

@ -69,6 +69,7 @@ type InstanceConfig struct {
Labels map[string]string
MachineType string
Metadata map[string]string
MinCpuPlatform string
Name string
Network string
NetworkProjectId string

View File

@ -377,7 +377,8 @@ func (d *driverGCE) RunInstance(c *InstanceConfig) (<-chan error, error) {
Metadata: &compute.Metadata{
Items: metadata,
},
Name: c.Name,
MinCpuPlatform: c.MinCpuPlatform,
Name: c.Name,
NetworkInterfaces: []*compute.NetworkInterface{
{
AccessConfigs: []*compute.AccessConfig{accessconfig},

View File

@ -111,6 +111,7 @@ func (s *StepCreateInstance) Run(_ context.Context, state multistep.StateBag) mu
Labels: c.Labels,
MachineType: c.MachineType,
Metadata: metadata,
MinCpuPlatform: c.MinCpuPlatform,
Name: name,
Network: c.Network,
NetworkProjectId: c.NetworkProjectId,