Terraform : Backends - Manage State Snapshots Remotely
This article gives an overview of how to manage state snapshots remotely in Terraform.
oracle miscconfigurationintermediate
by OracleDba
13 views
This article gives an overview of how to manage state snapshots remotely in Terraform.
12345678910111213141516171819
terraform {
backend "artifactory" {
username = "my-artifactory-username"
password = "my-artifactory-api-key"
url = "https://mycompany.jfrog.io/artifactory"
repo = "my-terraform-state"
subpath = "my-terraform-state"
}
}
username = "my-artifactory-username"
password = "my-artifactory-api-key"
url = "https://mycompany.jfrog.io/artifactory"
repo = "my-terraform-state"
subpath = "my-terraform-state"
terraform {
backend "artifactory" {}
}1234567891011121314151617181920212223242526272829303132
# Hard coded backend.
terraform init
# Backend config file.
terraform init -backend-config=config.artifactory.tfbackend
{
"version": 3,
"serial": 10,
"lineage": "66a209a2-609b-d6c6-4870-97731efde168",
"backend": {
"type": "artifactory",
"config": {
"password": "my-artifactory-api-key",
"repo": "my-terraform-state",
"subpath": "my-terraform-state",
"url": "https://mycompany.jfrog.io/artifactory",
"username": "my-artifactory-username"
},
"hash": 1831485929
},
"modules": [
{
"path": [
"root"
],
"outputs": {},
"resources": {},
"depends_on": []
}
]
}Please to add comments
No comments yet. Be the first to comment!