Variabilize GCE region and zone, only use hostname for cloud, not hostname+target
This commit is contained in:
parent
6603cc9518
commit
ba48937b12
@ -37,7 +37,7 @@ endef
|
|||||||
|
|
||||||
define OPACK_INSTALL_CLOUD_CONTENT =
|
define OPACK_INSTALL_CLOUD_CONTENT =
|
||||||
Choose your keyboard layout = fr
|
Choose your keyboard layout = fr
|
||||||
System hostname = $(OPACK_SYS_HOSTNAME)-$(OPACK_TARGET)
|
System hostname = $(OPACK_SYS_HOSTNAME)
|
||||||
Which network interface = vio0
|
Which network interface = vio0
|
||||||
IPv4 address for vio0 = dhcp
|
IPv4 address for vio0 = dhcp
|
||||||
IPv6 address for vio0 = none
|
IPv6 address for vio0 = none
|
||||||
@ -93,8 +93,8 @@ define OPACK_TERRAFORM_CONTENT =
|
|||||||
|
|
||||||
variable "credentials" { default = "../$(OPACK_GCE_JSON_KEY)" }
|
variable "credentials" { default = "../$(OPACK_GCE_JSON_KEY)" }
|
||||||
variable "project" { default = "$(OPACK_GCE_PROJECT)" }
|
variable "project" { default = "$(OPACK_GCE_PROJECT)" }
|
||||||
variable "region" { default = "europe-west4" }
|
variable "region" { default = "$(OPACK_GCE_REGION)" }
|
||||||
variable "zone" { default = "europe-west4-b" }
|
variable "zone" { default = "$(OPACK_GCE_ZONE)" }
|
||||||
|
|
||||||
provider "google" {
|
provider "google" {
|
||||||
region = "$${var.region}"
|
region = "$${var.region}"
|
||||||
|
@ -129,6 +129,12 @@ OPACK_GCE_JSON_KEY?=
|
|||||||
# OPACK_GCE_BUCKET: The Google Cloud Storage bucket name, typically associated with the project, for the image import.
|
# OPACK_GCE_BUCKET: The Google Cloud Storage bucket name, typically associated with the project, for the image import.
|
||||||
OPACK_GCE_BUCKET?=$(OPACK_GCE_PROJECT)
|
OPACK_GCE_BUCKET?=$(OPACK_GCE_PROJECT)
|
||||||
|
|
||||||
|
# OPACK_GCE_REGION: The Google Cloud Compute Engine region.
|
||||||
|
OPACK_GCE_REGION?=europe-west4
|
||||||
|
|
||||||
|
# OPACK_GCE_REGION: The Google Cloud Compute Engine zone.
|
||||||
|
OPACK_GCE_REGION?=europe-west4-b
|
||||||
|
|
||||||
# Define the machine type for the VM
|
# Define the machine type for the VM
|
||||||
OPACK_GCE_MACHINE?=e2-micro
|
OPACK_GCE_MACHINE?=e2-micro
|
||||||
|
|
||||||
@ -142,7 +148,7 @@ OPACK_TERRAFORM_DIR?=opack_deploy_$(OPACK_SHORT_REV)
|
|||||||
# Terraform module dir
|
# Terraform module dir
|
||||||
OPACK_TERRAFORM_MODULE_DIR?=$(OPACK_TERRAFORM_DIR)/opack-module
|
OPACK_TERRAFORM_MODULE_DIR?=$(OPACK_TERRAFORM_DIR)/opack-module
|
||||||
|
|
||||||
ifdef OPACK_DEBUG
|
ifndef OPACK_DEBUG
|
||||||
$(info ░ BOX $(OPACK_BOX_FILE))
|
$(info ░ BOX $(OPACK_BOX_FILE))
|
||||||
$(info ▒ HOSTNAME $(OPACK_SYS_HOSTNAME)-$(OPACK_TARGET))
|
$(info ▒ HOSTNAME $(OPACK_SYS_HOSTNAME)-$(OPACK_TARGET))
|
||||||
$(info ░ USER $(OPACK_SYS_USER))
|
$(info ░ USER $(OPACK_SYS_USER))
|
||||||
|
Loading…
Reference in New Issue
Block a user