mirror of
https://github.com/jpetazzo/container.training.git
synced 2026-05-24 17:52:45 +00:00
This is a new provisioning mechanism. Right now, it can provision clusters on: - Digital Ocean - Linode - Oracle Cloud - Scaleway Others should be relatively straightforward to add. Check the README in the prepare-tf subdirectory for details.
17 lines
353 B
HCL
17 lines
353 B
HCL
resource "random_string" "_" {
|
|
length = 5
|
|
special = false
|
|
upper = false
|
|
}
|
|
|
|
resource "time_static" "_" {}
|
|
|
|
locals {
|
|
tag = format("tf-%s-%s", formatdate("YYYY-MM-DD-hh-mm", time_static._.rfc3339), random_string._.result)
|
|
# Common tags to be assigned to all resources
|
|
common_tags = [
|
|
"created-by=terraform",
|
|
"tag=${local.tag}"
|
|
]
|
|
}
|